20/33 HELP anybody please


#1

// here we make bob using the Object constructor
var bob = new Object();
bob.name = "Bob Smith";
// add bob's age here and set it equal t
bob.age(20);


#2

Just as you set the name with an assignment, so too will you use the same approach for setting the age...

bob.age = 20;

It is a direct assignment that both declares the property and sets it in one statement.

To segue on to a future path, let's examine your code further and see what it implies.

bob.age = function (newAge) {
    this.howOld = newAge;
};
bob.age(20);
console.log(bob.howOld);     // 20