Question: Write a class named Dodecagon whose objects represent regular dodecagons (12-sided polygons). Your class should implement the Shape interface defined in this chapter. A Dodecagon
Write a class named Dodecagon whose objects represent regular dodecagons (12-sided polygons). Your class should implement the Shape interface defined in this chapter. A Dodecagon object is defined by its side length as passed to its constructor. The common formulas for the area and perimeter of a regular dodecagon are based on its circumradius, which is the radius of the smallest circle that would fully contain the dodecagon. We suggest reading about these formulas on a web site such as Wikipedia or Wolfram MathWorld.
Step by Step Solution
3.32 Rating (161 Votes )
There are 3 Steps involved in it
public class Dodecagon implements Shape private double sideLe... View full answer
Get step-by-step solutions from verified subject matter experts
