CSC 172
Homework 3
Assigned 27 Sept, due 4 Oct
-
Before you start, fill out a Product Plan Estimate form in the PSP
package (click on "Input" under "Product Plan Estimates").
-
As you go, or when you're done, fill out a time log form in the
PSP package (click on "Input" under "Time Management Data").
-
Every time you find and fix a defect, record it using the PSP package
(click on "Input" under "Defect Removal Data").
-
For this and all your programming assignments, follow the appropriate design
recipe(s). Among other things, each method should be documented with
examples and the results they should produce (write these before
writing the code!); be sure to test the method thoroughly before turning
it in.
-
Each class, method, and variable should have a well-chosen, meaningful
name.
-
Each class should have a static void test() method where you put
all your standard test cases relevant to this class.
-
All javadoc comments (and all comments, for that matter)
should be correct and up-to-date; a misleading comment is worse than none
at all.
-
Modify your collection of classes from homework 2 by adding a Shape
class with appropriate abstract (and not-so-abstract) methods. Try
to avoid duplication of code. The Shape class doesn't need
a toString method or an equals method, since all of its
concrete subclasses already have those (from homework 2; if you didn't
write them for homework 2, write them now), but it should have its own
test
method that tests the ability to work with different kinds of shapes, and
in particular the ability to store different kinds of shapes in Shape
variables and have them behave appropriately.
Last modified: Sat Feb 26 09:45:12 EST 2000
Stephen Bloch / sbloch@adelphi.edu