JavaScript Developer — Medium
Key points
- Dog class overrides the speak method from the Animal class
- The new Dog instance 'd' is created with the name 'Rex'
- The speak method of 'd' outputs 'Rex barks.'
Ready to go further?
Related questions
JavaScript Developer — Medium
Key points
Ready to go further?
Related questions