Skip to content

Instantly share code, notes, and snippets.

@DominicGBauer
Last active January 16, 2019 12:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save DominicGBauer/223a32f0d8fe6839a98ece0b78cc5a10 to your computer and use it in GitHub Desktop.
Save DominicGBauer/223a32f0d8fe6839a98ece0b78cc5a10 to your computer and use it in GitHub Desktop.
newMaster
class Master {
tenThousandHours(sweat) {
this.sweat = sweat;
}
grind() {
console.log(this.sweat);
}
}
// create a new instance of master called yoda
const yoda = new Master();
// use the tenThousandHours method with a string input
yoda.tenThousandHours('sweaty, knees weak, arms are heavy');
// use the grind method
yoda.grind();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment