title: print an array of objects in javascript
body: <p>Hello I need help accessing elements of objects in my JavaScript
  What's the error of this one</p>
  
  <pre><code>var people = [
      {
          name: "Jake",
          age: 20
      },
  {
          name: "John",
          age: 23
      },
  {
          name: "Mike",
          age: 21
      },
  ]
  
  
  
  for (var i=0; i &lt; 3 ;i++)
      document.getElementById("myDiv").innerHTML += "Name: " + people[i].name + "Age: "+ people[i].age +"\n"; 
  </code></pre>
  
  <p>I only need to write to the div the values of the array of objects</p>