Problem 2: Right Cylinder Volume Write a program yourname_volume.py that prints the volume of a right cylinder given the
Posted: Tue Jul 05, 2022 10:19 am
Problem 2: Right Cylinder Volume Write a program yourname_volume.py that prints the volume of a right cylinder given the base's circumference and the cylinder's height. The program should be written as three functions: main(): takes in two piece of input from the user as floats (the cylinder's base circumference and the cylinder's height), calls other functions, and prints the result. calculate_radius(circumference): takes the base's circumference as a parameter and calculates the base's radius. Return the radius as a float. calculate_volume(radius, height): takes the base's radius and the cylinder's height as parameters and calculates the volume. Return the volume as a float. CALCULATE RADIUS GIVEN CIRCUMFERENCE r = C 2 п circumference radius CALCULATE VOLUME GIVEN RADIUS AND HEIGHT V = лr²h height radius