The perimeter method is implemented in the superclass as it


The perimeter method is implemented in the superclass as it does not change based on the number of sides.

The area method must be overridden in each subclass as the area is dependent on the type of polygon.

The areas of an equilateral triangle, square, and a regular hexagon given side length a are v 3 4 a 2 , a 2 , and 3 v 3 2 a 2 , respectively.

The superclass area method should just return 0 as a default value.

Request for Solution File

Ask an Expert for Answer!!
Computer Engineering: The perimeter method is implemented in the superclass as it
Reference No:- TGS02886346

Expected delivery within 24 Hours