Question: The world of shapes is much richer than the shapes included in the inheritance hierarchy of Fig. 11.3. Write down all the shapes you can
The world of shapes is much richer than the shapes included in the inheritance hierarchy of Fig. 11.3. Write down all the shapes you can think of—both two dimensional and three-dimensional—and form them into a more complete Shape hierarchy with as many levels as possible. Your hierarchy should have class Shape at the top. Class Two Dimension-al Shape and class Three Dimensional Shape should extend Shape. Add additional derived classes, such as Quadrilateral and Sphere, at their correct locations in the hierarchy as necessary.
Step by Step Solution
3.32 Rating (155 Votes )
There are 3 Steps involved in it
TwoDimensionalShape Quadrilateral Trap... View full answer
Get step-by-step solutions from verified subject matter experts
