Skip to content
Snippets Groups Projects
Commit 4c5b9591 authored by Mathea Berg Vindsetmo's avatar Mathea Berg Vindsetmo
Browse files

Chicken

parent 30142d18
Branches
No related tags found
No related merge requests found
package of5_2.kode;
public class Chicken implements Animal{
private int age;
private String name;
public Chicken(String name, int age) {
this.name = name;
this.age = age;
}
@Override
public String getName() {
return name;
}
@Override
public int getAge() {
return age;
}
@Override
public String makeSound() {
return name + " sier klukk!";
}
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment