public static void main(String[] args) {
Human person = new Human();
Cat fluffy = new Cat();
Meal breakfast, lunch, dinner = new Meal();
TaskList chores = new TaskList();
Meal breakfast, lunch, dinner = new Meal();
TaskList chores = new TaskList();
for (int i = 1; i <=
365; i++)
{
int day = i % 7;
fluffy.wakeUp();
fluffy.wakeHuman(person);
person.feedCat(fluffy);
person.getDressed();
person.eat(breakfast);
if (day == 0)
person.goToChurch();
else if (day == 6) {}
else
person.goToWork();
while (!chores.areDone() )
{
person.doTasks(chores);
if (person.isHungry() )
{
person.goToKitchen();
person.eat(lunch);
}
}
person.setFreeTime(true);
while (person.hasFreeTime() && !person.isTired() )
{
person.play();
if (person.isHungry() )
{
person.goToKitchen();
person.eat(dinner);
}
}
person.feedCat(fluffy);
if (person.isTired() )
person.goToBed();
}
}
No comments:
Post a Comment