title: JavaScript: Split array into individual variables
body: <p>Considering this data structure:</p>
  
  <pre><code>var vehicles = [
    [ "2011","Honda","Accord" ],
    [ "2010","Honda","Accord" ],
    .....
  ];
  </code></pre>
  
  <p>Looping through each <em>vehicles</em> item, is there a way to reassign the array elements to individual variables all in one shot, something like:</p>
  
  <pre><code>for (i = 0; i &lt; vehicles.length; i++) {
    var(year,make,model) = vehicles[i]; // doesn't work
    .....
  }
  </code></pre>
  
  <p>... I'm trying to get away from doing:</p>
  
  <pre><code>for (i = 0; i &lt; vehicles.length; i++) {
    var year = vehicles[i][0];
    var make = vehicles[i][1];
    var model = vehicles[i][2];
    .....
  }
  </code></pre>
  
  <p>Just curious since this type of thing is available in other programming languages. Thanks!</p>