Without extends the child inherits nothing.
Acceptance criteria
- 1.#out should show some sound.
Without extends the child inherits nothing.
class Animal { speak() { return "some sound"; } } class Dog {} const dog = new Dog(); document.querySelector('#out').textContent = typeof dog.speak === "function" ? dog.speak() : "nothing was inherited";
Output ready when you are
Press Run to render your code, or Submit to validate your solution.