4/30 Passed but the error message: ReferenceError: job is not defined


var james = {
job: "programmer",
married: false,
sayJob: function() {
// complete this method
console.log("Hi, I work as a " + job)

// james' first job

// change james' job to "super programmer" here
james.sayJob("super programmer");

// james' second job
james.sayJob("AI expert");


The sayJob method takes no parameter. It refers to the instance variable, this.job internally. Be sure to change your variable in the method.

To set a value,

james.job = 'super programmer';  
james.sayJob();                 // logs super programmer


solved it thanks mtf!!