Created
November 29, 2019 17:35
-
-
Save Dornhoth/979a16ff3bbf9ffc0d3ca33303514175 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
interface Person { | |
greet(): string; | |
} | |
class Student implements Person { | |
public greet(): string { | |
return 'Hi!'; | |
} | |
} | |
class Teacher implements Person { | |
public greet(): string { | |
return 'Hello!'; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment