This program should import program5_2 as a module. The main function should prompt the user for the radius (as a float) and execute the imported functions. Outputs should display the same number of decimals as program5_2.py.
This file requires a main function and two custom functions about circles. Both functions take the radius of a circle as an argument. One function returns the area of the circle. The other void function prints the circumference of a circle to three decimal places. The main function should prompt the user for the radius (as a float) and execute the custom functions. The value returned by the area function should be printed accurate to four decimal places. Use the math module to get the value of pi.
Sample Output
program5_3.py
This program should import program5_2 as a module. The main function should prompt the user for the radius (as a float) and execute the imported functions. Outputs should display the same number of decimals as program5_2.py.
Trending now
This is a popular solution!
Step by step
Solved in 3 steps with 1 images
Where is the void function for circumference