Answered step by step
Verified Expert Solution
Question
1 Approved Answer
J Hexagon ava > & Hexegon Jublic class Hexagon extends Geoshape ( private double sitdes c I / write your code here I / initialize
Hexagon ava & Hexegon
Jublic class Hexagon extends Geoshape
private double sitdes
c
Iwrite your code here
I initialize the color and name in the 'Geoshape' super class
set the side value, do not use assignment for this
private void sotside double length
i
II write your code here
II assign the 'side' from length
I
public double getarea
i
write your code here
II return the area of a regular hexagon all sides equal
II hint use 'Math.sqrt to get square root
here is a formula: httpsisocraticorgquestionshowdoicalculatetheareaofahexagon
public double gatereringerer
i
I write your code here
II return the perimeter of a regular hexagon all sides equal
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started