title: what is for....in statement in javascript
body: <p>anyone can explain how to use for...in statement in javascript. I had read the w3school article but i think it is not so clear.Below is the code, please explain this:</p>
  
  <pre><code>&lt;html&gt;
  &lt;body&gt;
  &lt;script type="text/javascript"&gt;
  var x;
  var mycars = new Array();
  mycars[10] = "Saab";
  mycars[20] = "Volvo";
  mycars[30] = "BMW";
  
  for (x in mycars)
  {
  document.write(mycars[x] + "&lt;br /&gt;");
  }
  &lt;/script&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>