Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

python programming Save program in a file called task1.py and the plan in a file called plan1.txt. Calculate the area of a regular polygon. A

python programming

Save program in a file called task1.py and the plan in a file called plan1.txt. Calculate the area of a regular polygon. A regular polygon is one in which all sides are the same length and the angles all have the same degree. The formula for the area of a regular polygon is

image text in transcribed

where n is the number of sides and s is the length of each side. Prompt the user for the length and number of sides and display the result, with an appropriate message, to the user.

You must use the math modules for pi, tan(), and pow(). You must use different techniques for importing in order to use items from the module exactly as follows (with the appropriate parameters) in your code:

tan() math.pow() pi

Output should be rounded to 5 decimal places using the round() function.

Area = Axtar($) nx 82

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Fundamentals Of Database Management Systems

Authors: Mark L. Gillenson

3rd Edition

978-1119907466

More Books

Students also viewed these Databases questions