title: How can JavaScript arrays have non-numeric keys?
body: <p>What I have learned is an array is a type of object. Objects are a collection of properties with key/value pairs. I always thought arrays are a collection of items that are numerically indexed starting at 0. Just recently, I was able to add a non-numeric key to an array.</p>
  
  <pre><code>let arr = ['cribriform plate','mastoid','hyoid'];
  arr.eyes = 'brown';
  arr.skin = 'white';
  </code></pre>
  
  <p>That resulted in</p>
  
  <pre><code>['cribriform plate','mastoid','hyoid',eyes : 'brown', skin : 'white'];
  </code></pre>
  
  <p>The for...in loop of arr yielded:</p>
  
  <pre><code>for(let i in arr){
      console.log(i);
      //0,1,2,3,eyes,skin
  }
  </code></pre>
  
  <p>The for...of loop yielded:</p>
  
  <pre><code>for(let i of arr){
       console.log(i);
       //0,1,2,3
  }
  </code></pre>
  
  <p>I was able to iterate over all the keys of an array using the for...in loop. However, when I used the for...of loop, I was only able to iterate over the numerically indexed keys. Why is that?</p>
  
  <p>And, what is the most accurate definition of an array?</p>