This file contains 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
void main(){ | |
Lecture<String> lecture1 = Lecture('123','lecture1'); | |
lecture1.printIdType(); | |
} | |
// generic - 타입을 외부에서 받을때 사용 | |
This file contains 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
void main(){ | |
BoyGroup bts = BoyGroup('BTS'); | |
print(bts is IdolInterface); | |
} | |
abstract class IdolInterface{ | |
String name; | |
This file contains 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
void main(){ | |
TimesTwo tt = TimesTwo(2); | |
print(tt.calculate()); | |
TimesFour tf = TimesFour(2); | |
print(tf.calculate()); | |
} |