Skip to content

Commit e8b502b

Browse files
committed
Added homework assignment
1 parent b62917a commit e8b502b

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed

HOMEWORK

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
INSTRUCTIONS
2+
3+
* Fork this repository to complete the homework assignment.
4+
* Add or update your code for each of the activities below.
5+
* When finished, push your work to your github account.
6+
* We will review the homework and any questions you may have about the
7+
assignment at the beginning of class 2.
8+
9+
HOMEWORK
10+
11+
1. Add another penguin to the zoo. It should appear in the list of penguins
12+
with out modification to the current output code in the main function
13+
of Zoo.
14+
15+
2. When a penguin eats a fish, the full weight of the fish should not be
16+
added to the weight of the penguin (current behavior). Instead add 3/4 the
17+
weight of the fish to the penguin's weight.
18+
19+
3. When a penguin swims, it loses five pounds.
20+
21+
4. A penguin dies when it weighs 0 pounds. Add a function to check the weight
22+
before a penguin swims. Add a way to track if a penguin is dead.
23+
24+
EXTRA CREDIT
25+
26+
* Add an aquarium to hold fish.
27+
* Add three fish to the aquarium with different characteristics.
28+
* Add the aquarium to the zoo and add print statements to describe it.
29+
30+
OBJECTIVES
31+
32+
* Become comfortable with github, checking out a repository, and pushing
33+
changes to github.com.
34+
* Become familiar with IntelliJ.
35+
* Practice with Java variables, functions, arrays, math operations,
36+
and objects.

0 commit comments

Comments
 (0)