Skip to main content

JavaScript Question 55

Question 55 of 0JavaScript

What's the output?

Login Required

Please login to select answers and solve this question. You can view the question without logging in.

Code:
class Dog {
  constructor(name) {
    this.name = name;
  }
}

Dog.prototype.bark = function() {
  console.log(`Woof I am ${this.name}`);
};

const pet = new Dog('Mara');
pet.bark();

delete Dog.prototype.bark;

pet.bark();

Select the correct option: