title: What is the best way to create an array of objects in Javascript?
body: <p>I understand that in Javascript, I can create an object like this:</p>
  
  <pre><code>var cup = {};
  </code></pre>
  
  <p>Furthermore, I can set properties like this: </p>
  
  <pre><code>cup.color = 'Blue';
  cup.size = 'Large';
  cup.type = 'Mug';
  </code></pre>
  
  <p>Can I create an array of cups? For example: </p>
  
  <pre><code>cup[0].color = 'Blue';
  cup[1].size = 'Large';
  cup[2].type = 'Mug';
  </code></pre>