I'm re-learning JavaScript at the moment.
My tutor told me today that in JavaScript, "everything is an object". In fact, using a for-in loop, you can iterate over an object's properties just like you can over an array's elements.
I now have (yet another) naive question: If everything in JavaScript is an Object, why do people "bother" using Arrays?
My first guess is there must be methods on Array that aren't available on Object (which a quick and superficial glance at MDN seems to confirm), and Arrays can be indexed (i.e. myArray[i]) (and have a length). But is that the whole story? Or is there some performance gain to be had by using the built-in Array (object) data type?