again = "y" while str.lower(again)=="y": response = input("Do you want to calculate the volume of a cylinder or the volume of a cuboid? (CL OR CU) ") realPi = float(3.14159) def cylindervol(radius,length): realVolume = realPi*realRadius*realLength print('The volume of the cylinder is: ') print(realVolume) def cuboidvol(): realVolume = realHeight*realWidth*realLength print("The volume of the cuboid is: ") print(realVolume) if str.lower(response)=="cl": realRadius=float(input('Enter the radius of the cylinder :')) realLength=float(input('Enter the length of the cylinder :')) cylindervol(realRadius,realLength) again = input('Do you want to calculate another?(Y or N)') if str.lower(response)=="cu": realWidth=float(input('Enter the width of the cuboid :')) realLength=float(input('Enter the length of the cuboid :')) realHeight=float(input('Enter the height of the cuboid :')) cuboidvol() again = input('Do you want to calculate another?(Y or N)')