Course · Section 14: Object-Oriented Programming (OOP) With JavaScript · Lecture 226: ES6 Classes
Using a constructor function and its prototype (not the `class` keyword), give `Speaker` a `greet()` method. Implement `greetWith(name)` returning `Hi ` followed by the name.
+ 1 hidden test run on Submit.
Putting greet on the prototype shares one method across instances, the mechanism classes use under the hood.
Run your code to see results.