19. Create an abstract class called GeometricFigure. Each figure includes a height, a width, a figure type,
and an area. Include an abstract method to determine the area of the figure. Create two subclasses
called Square and Triangle. Create an application that demonstrates creating objects of both subclasses
and store them in an array. Save the file as GeometricFigure.java, Square.java, Triangle.java and
UseGeometric.java.
20. Modify Lab Exercise 19, adding an interface called SidedObject that contains a method called
displaySides(); this method displays the number of sides the object possesses. Modify the
GeometricFigure subclasses to include the use of the interface to display the number of sides of the
figure. Create an application that demonstrates the use of both subclasses. Save the files as
GeometricFicure2.java Square2.java, Triangle2.java, SidedObject.java, and UseGeometric2.java
1
Expert's answer
2012-08-16T09:20:28-0400
Unfortunately, your question requires a lot of work and cannot be done for free. Submit it with all requirements as an assignment to our control panel and we'll assist you.
Numbers and figures are an essential part of our world, necessary for almost everything we do every day. As important…
APPROVED BY CLIENTS
Finding a professional expert in "partial differential equations" in the advanced level is difficult.
You can find this expert in "Assignmentexpert.com" with confidence.
Exceptional experts! I appreciate your help. God bless you!
Comments
Leave a comment