a3 part 1

This commit is contained in:
2022-04-11 11:02:56 +08:00
parent 5e9fc07694
commit 72874e2cc3
3 changed files with 91 additions and 0 deletions

33
assignment3/Human.java Normal file
View File

@@ -0,0 +1,33 @@
/*
* Author: CHEN Yongyuan (Walter) 1930006025 from OOP(1007)
* Date: 2022-04-11
* Description: Human class
*/
public class Human extends Mammal {
/**
* Constructor.
*
* The Constructor take no argument. All human are named "Alice"
*/
public Human() {
super("Alice");
}
/**
* Human cannot be cooked.
*
* @return false
*/
@Override
public boolean isCookable() {
return false;
}
/**
* Test.
*/
public static void testHuman() {
}
}