Created
September 18, 2021 03:29
-
-
Save ebwood/d68e1c6c8f83c6d69775bd2122fbe422 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
mixin Dog { | |
void run() { | |
print('Dog run'); | |
} | |
void walk() { | |
print('Dog walk'); | |
} | |
} | |
mixin Cat { | |
void run() { | |
print('Cat run'); | |
} | |
void catWalk() { | |
print('Cat catWalk'); | |
} | |
} | |
class Human with Dog, Cat {} | |
void main(List<String> arguments) { | |
Human human = Human(); | |
human.walk(); | |
human.run(); | |
human.catWalk(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment