Question: abstract classes and interfaces Design a new Triangle class that extends the abstract GeometricObject D class. (The source code for this abstract class can be

abstract classes and interfaces

abstract classes and interfaces Design a new Triangle class that extends the

Design a new Triangle class that extends the abstract GeometricObject D class. (The source code for this abstract class can be found in chapters 9, 11, & 13 in Files). Write a test program that prompts the user to enter three sides of the triangle (make sure they define an actual triangle), a color, and a Boolean value to indicate whether the triangle is filled. The program should then create a Triangle object with these sides and set the color and filled properties using the input, in addition to circle and rectangle objects. The program should display, for each of these geometric objects, the area, perimeter, color, and true or false to indicate whether it is filled or not

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!