Hello? yes this is doge



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 + " dog")

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

var myDog = new Dog("dachshund");


so my code works and I can move on to the next exercise, but nothing is logging on the console whats going on?


I input your code in the console and it ran fine for me. Try restarting/using a different browser? I don't see any problems with it.


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