In Javascript, what is a sure way to loop through an array of 3 strings?
<p>Something like this works, but looks a bit clumsy:</p>

<pre><code>for (i in {foo: 1, bar: 1, wah: 1}) {  // loops through foo, bar, wah
  console.log(i + " haha");            // can view using Firebug or Chrome 
}
</code></pre>

<p>if using an array, I don't want to create any global temporary variable for the array...  Also, this has to work in any modern browser IE7 / FF / Chrome / Safari.  thanks.</p>
