Write a java program that: Create an abstract class named Shape that contains three integers length, breadth, radius and an empty method named printArea(). Provide three classes named Rectangle,...


Write a java program that:



  1. Create an abstract class named Shape that contains three integers length, breadth, radius and an empty method named printArea().

  2. Provide three classes named Rectangle, Triangle and Circle such that each one of the classes extends the class Shape.

  3. Each one of the classes contains only the method printArea() that read the requested values and prints the area of the given shape.

  4. Provide a class Main that create a rectangle, a triangle and a circle then print their respective areas.



Jun 11, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here