1
2var myDog = {
3 "name": "Coder",
4 "legs": 4,
5 "tails": 1,
6 "friends": ["freeCodeCamp Campers"]
7};
8
9// Update the name value
10myDog.name = "Happy Coder";
1var myDog = {
2 "name": "Coder",
3 "legs": 4,
4 "tails": 1,
5 "friends": ["freeCodeCamp Campers"]
6};
7
8myDog.name = "Happy Coder"
9console.log(myDog.name);
10//or
11myDog["name"] = "Happy Coder"
12console.log(myDog["name"]);