Question: help? Problem a (LA2a.java) Write a program to compute the area, perimeter, and interior angle of a regular polygon. First, have the user supply the

 help? Problem a (LA2a.java) Write a program to compute the area,

help?

Problem a (LA2a.java) Write a program to compute the area, perimeter, and interior angle of a regular polygon. First, have the user supply the number of sides of the polygon (a whole number, which must be 3 or greater) and the side length (any positive number). Then, compute the area via the following equation: sn Area = 4tan cang where n is the number of sides and s is the side length. (please use Math.PI to do the calculation, tan you can use Math.tan() to calculate.). Then, compute the perimeter via the following equation: Perimeter = ns and then the interior angle (in degrees) via the following equation: 360 Interior Angle = 180 n So, an example run of your program would look like the following: Enter number of sides: 3 Enter side length: 1 Area: 2.433 Perimeter: 3.000 Interior Angle: 60.000 degrees

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 Databases Questions!