Literally Speaking


#1


https://www.codecademy.com/courses/objects-ii/0/3?curriculum_id=506324b3a7dffd00020bf661#


Error: Oops, try again. It looks like your speak method doesn't properly take in a single argument and output the correct string.


var james = {
    job: "programmer",
    married: false,
    speak: function(mood) {
        console.log(mood)
    }
};

james.speak("Hello, I am feeling great");
james.speak("Hello, I am feeling just okay");

(It does print those)


#2

They only ask you to modify the speak function, you changed more things than that (I suggest hitting the reset button)


#3

niftrex, it's because you should console.log("Hello, I am feeling " + mood);
And don't change lines 9-10, where james.speak() method is written, you should not modify the text in the parenthesis.
Rewrite them to:
james.speak("great");
james.speak("just okay");


#4

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