I am creating a program which has the following requirements:
-Class named Point must be superclass of the hierarchy
-Square and Cube are subclasses of Point
-Private data of Point are the x and y coordinates
-Private data of Square is sideLength
-Private data of Cube is depth
-Use accessor, mutator, toString(), volume, and area methods when applicable
Given that the volume of a cube is length x width x height (depth) and the area of a square is length x width, the formulas to calculate these figures are very simple. However, I have really no idea how Point (x,y) play into this scenario. It seems to me that width, instead of x and y, would make more sense.
Doe anyone know what the program requirements are suggesting here, specifically relating to the Point class?