- Write a Python program (with comments) to do the following:
- Define a function
**calc_angle(***n*that calculates the**)**of a regularpolygon with*interior angle*sides and returns this value. Use the following formula:*n*

- Define a function

** angle** =(

**-2)*180/**

*n*

*n*- In the main program, ask the user to input thenumber of sides of the regular polygon and assign the numericalvalue to variable
.Assume a valid entry will be given.*num_sides* - Call the above function with its
asits input and print the value returned by the function with asuitable message.*num_sides* - Save your code to a file with name
.*lab9sol.py* (i.e.**Submit your Python code**file)*lab9sol.py***throughBB.**

A sample output is shown below.

Sign in Upgrade – 0 X + Imert Rye Layout Delcreness levien View Section cloud Q Click to find commande WWFs Office labs. doc x = Menu Home Xother New Roman 2 Paste cap Format BIV -A-XX A 2 AA 22. SE A A – A – ABOCA ABLABCAaBbc. A Nora Heading Heading 2 Headings, New Style Q Tee Topia Find and Select Settings Le Python 3.6.2 Shell File Edit Shell Debug Options Window Help ====== RESTART: C:UsersArunita JaekelDropbo x106LABSF19lab9sol.py === Enter the number of sides in your polygon: 4 The interior angle of a regular polygon with 4 sides is: 90.0 >>> ====== RESTART: C:UsersArunita JaekelDropbo x106LABSF19lab9sol.py ===== Enter the number of sides in your polygon: 7 The interior angle of a regular polygon with 7 sides is: 128.57142857142858 >>> ====== RESTART: C:UsersArunita JaekelDropbo x106LABSF19lab9sol.py ====== Enter the number of sides in your polygon: 10 The interior angle of a regular polygon with 1 0 sides is: 144.0 2003 297*. – E H H Pape Nume: 1 Page 11 Sector 1 SetValue: 2.5in tow Count Word 115/130 2 Suel Che Compatibility Mode ó tial. A. HIMELIE 4 | = A 4 ENG 20191165 Show transcribed image text Sign in Upgrade – 0 X + Imert Rye Layout Delcreness levien View Section cloud Q Click to find commande WWFs Office labs. doc x = Menu Home Xother New Roman 2 Paste cap Format BIV -A-XX A 2 AA 22. SE A A – A – ABOCA ABLABCAaBbc. A Nora Heading Heading 2 Headings, New Style Q Tee Topia Find and Select Settings Le Python 3.6.2 Shell File Edit Shell Debug Options Window Help ====== RESTART: C:UsersArunita JaekelDropbo x106LABSF19lab9sol.py === Enter the number of sides in your polygon: 4 The interior angle of a regular polygon with 4 sides is: 90.0 >>> ====== RESTART: C:UsersArunita JaekelDropbo x106LABSF19lab9sol.py ===== Enter the number of sides in your polygon: 7 The interior angle of a regular polygon with 7 sides is: 128.57142857142858 >>> ====== RESTART: C:UsersArunita JaekelDropbo x106LABSF19lab9sol.py ====== Enter the number of sides in your polygon: 10 The interior angle of a regular polygon with 1 0 sides is: 144.0 2003 297*. – E H H Pape Nume: 1 Page 11 Sector 1 SetValue: 2.5in tow Count Word 115/130 2 Suel Che Compatibility Mode ó tial. A. HIMELIE 4 | = A 4 ENG 20191165

## Expert Answer

Answer to Write a Python program (with comments) to do the following: Define a function calc_angle(n) that calculates the interior…