Solved

Case Study 1: ≫>> Import Math

Question 25

Essay

Case Study 1:
>>> import math
>>> numSides = 8
>>> innerAngleB = 360.0 / numSides
>>> halfAngleA = innerAngleB / 2
>>> oneHalfSideS = math.sin(math.radians(halfAngleA))
>>> sideS = oneHalfSideS * 2
>>> polygonCircumference = numSides * sideS
>>> pi = polygonCircumference / 2
>>> pi
3.0614674589207183
-Refer to the session in the accompanying Case Study 1. Explain, in general terms, how to modify this series of statements in such a way that you would be able to change the number of sides and try the calculation again without needing to retype all of the statements.

Correct Answer:

verifed

Verified

One way to accomplish this is to use abs...

View Answer

Unlock this answer now
Get Access to more Verified Answers free of charge

Related Questions

Unlock this Answer For Free Now!

View this answer and more for free by performing one of the following actions

qr-code

Scan the QR code to install the App and get 2 free unlocks

upload documents

Unlock quizzes for free by uploading documents