Skip to content

Instantly share code, notes, and snippets.

@mcsee
Last active August 22, 2023 23:40
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 mcsee/5c0218fcf1362228f406e463f79171a9 to your computer and use it in GitHub Desktop.
Save mcsee/5c0218fcf1362228f406e463f79171a9 to your computer and use it in GitHub Desktop.
class Animal { }
class Rabbit extends Animal {
move() {
console.log("I'm running");
}
}
class Seagull extends Animal {
move() {
console.log("I'm flying");
}
}
let bunny = new Rabbit();
let livingstone = new Seagull();
bunny.move();
livingstone.move();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment