Hello? this is dog (urgent help please)


#1

https://www.codecademy.com/en/courses/objects-ii/5/2?curriculum_id=506324b3a7dffd00020bf661#


It logs the correct answer to the console, but still gives me this error. Please help me out.
error message: Oops, try again. It appears that your sayHello method doesn't properly log to the console 'Hello this is a [breed] dog' where [breed] is the breed of the Dog

function Dog (breed) {
    this.breed = breed;
};

// add the sayHello method to the Dog class 
// so all dogs now can say hello
Dog.prototype.sayHello = function() {
    console.log("Hello this is a "+this.breed);
};

var yourDog = new Dog("golden retriever");
yourDog.sayHello();

var myDog = new Dog("dachshund");
myDog.sayHello();


#2

oooh. I've seen it. I didn't add "dog" to my print .:relieved: silly me


#3

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