I don't get why this worked 3.5


#1

function Cat(name, breed) {
this.name = name;
this.breed = breed;
}

// let's make some cats!
var cheshire = new Cat("Cheshire Cat", "British Shorthair");
var gary = new Cat("Gary", "Domestic Shorthair");

// add a method "meow" to the Cat class that will allow
// all cats to print "Meow!" to the console

function Cat(name, breed) {
this.name = name;
this.breed = breed;
}

// let's make some cats!
var cheshire = new Cat("Cheshire Cat", "British Shorthair");
var gary = new Cat("Gary", "Domestic Shorthair");

// add a method "meow" to the Cat class that will allow
// all cats to print "Meow!" to the console
Cat.prototype.meow = function() {
console.log("Meow!");
};
buddy.bark();

// add code here to make the cats meow!
// add code here to make the cats meow!


#2

@agentsks13gmail_com,

ReferenceError: buddy is not defined

#3

Add

cheshire.meow();
gary.meow();

and remove

buddy.bark();