class Person { #name : string ; private fav ? : string ; name : string ; readonly #other5 ? : string ; constructor ( name , fav ? ) { this . #name = name ; this . name = name ; this . fav = fav ; } greet ( ) { console . log ( `Hello, my name is ${ this . #name }!${ this . fav ? ` I like ${ this . fav }.` : "" }` ) ; } } class Person2 extends Person { #name : string ; constructor ( name ) { super ( name + "👍" ) ; this . #name = name ; } greet2 ( ) { console . log ( `Hi, I'm ${ this . #name }.` ) ; } } let papyrus = new Person ( "Papyrus" , "🐾" ) ; papyrus . greet ( ) ; let sans = new Person2 ( "Sans" ) ; sans . greet ( ) ; sans . greet2 ( ) ; let mimic2 = sans ;