Define the constructor property on the Dog prototype.

help!

Dog.prototype = {
  constructor: Dog, // Solution
  numLegs: 2,
  eat: function() {
    console.log("nom nom nom");
  },
  describe: function() {
    console.log("My name is " + this.name);
  }
};

What is your question? Also, please provide a link to the challenge.

1 Like

Define the constructor property on the Dog prototype.

Object Oriented Programming: Remember to Set the Constructor Property when Changing the Prototype | freeCodeCamp.org

Ok, but what is your question? If you defined the prototype as you show above and did not delete the Dog function, your code would pass the tests.

1 Like

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