Created
September 16, 2019 22:27
-
-
Save DiegoCarvalho75/ed6afe75e86554f5a814e75edc010bc6 to your computer and use it in GitHub Desktop.
Dart Pad OO
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
mixin Agility{ | |
var speed = 10; | |
void sitDown(){ | |
print('Sittin down'); | |
} | |
} | |
class Mammal{ | |
void breath(){ | |
print('Breath in breat out'); | |
} | |
} | |
class Person extends Mammal{ | |
String name; | |
int age; | |
Person(this.name, this.age); | |
} | |
void main() { | |
final pers = Person('max',30); | |
print (pers.name); | |
pers.breath(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment