16. Please help on "Editing an Existing Object"


#1


https://www.codecademy.com/en/courses/javascript-beginner-en-9Sgpi/3/3?curriculum_id=506324b3a7dffd00020bf661#


Code works but in the write up it says add a new key. Key and property are interchangeable, right?


var myObject = {
  name: 'Eduardo',
  type: 'Most excellent',
  // Add your code here!
  interests: [0, 1]
  
};


#2

Hello @kevin.reliancegmail,

Key isn't interchangeably referred to as property. An object has properties (key: value).

So, in this case, interests: [0, 1] is a property of the object myObject with interests as key and [0, 1] as its value.

Hope this helps! :slight_smile:


#3

bayoishola,

That definitely helps! Thank you. Just to confirm, the property is the 'key' and the 'value'. And the key is just the key, right?

Thanks bayoishola!

Kevin


#4

Yes, that's it.

You're welcome.

Have fun coding! :slight_smile:


#5

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.