Extending what @stetim94 explained to you, languages have different data types. Some combine things together such as
console.log(typeof bob); //-> object
bob is an “object” data type. Right? We can also express it as an associative array, meaning that we have a key/value pair relationship.
As @stetim94 said, it is confusing. Absolutely. When we wrap up other representations into one data type, it can be confusing when we know about arrays as defined in computer science.
But you can think of an
You can learn more here on MDN: