Skip to content

Instantly share code, notes, and snippets.

@Hackathonwave
Created November 10, 2023 12:47
Show Gist options
  • Save Hackathonwave/35afe1526127da30390b2bbf28fce78e to your computer and use it in GitHub Desktop.
Save Hackathonwave/35afe1526127da30390b2bbf28fce78e to your computer and use it in GitHub Desktop.
class Dog {
String breed;
int age;
String name;
Dog(this.breed, this.age, this.name);
void bark(){
print("woof!");
}
void fetch () {
print("Fetching the ball!");
}
}
void main() {
var myDog = Dog('Librator', 3, 'max');
myDog.bark();
myDog.fetch();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment