Get random element from associative array in javascript?
<p>I am building a playlist of songs in javascript. I have used an associative array <code>foo</code> -- the structure of my object looks akin to: </p>

<pre><code>foo[songID] = songURL;
</code></pre>

<p>I am trying to build in shuffling functionality. I would like to select a song at random from this list. Is there a simple way to do this -- the array is not indexed.</p>
