Question: Create a program to compute the fee for parking in a garage for a number of hours. The program should: Prompt the user for how
Create a program to compute the fee for parking in a garage for a number of hours. The program should:
Prompt the user for how many hours parked
Calculate the fee based on the following rules:
$hour
minimum fee is $
maximum fee is $
Print the result
For your program, define and use the following two functions:
# use input to prompt for the # of hours parked, and return this value
def getParkingHours:
# takes as input hours a number and returns the parking fee
def calcParkingFeehours:Convert the program to a "Modularized" menu driven program, the zipped folder linked below contains a modularized menu driven program.
The two functions you created in step getParkingHours calcParkingFeehours above are to be saved in a DIFFERENT file so both functions in ONE file give the file a discriptive name.
The main file is to display the menu shown below and call the functions you saved in that other file, whenif the user chooses to compute parking fee.
Note the program should only stop if the user enters meaning the only when the user chooses to stop.
If a value other than or is entered, the program should display a statement that tells the user the value they entered is invalid and then display the menu again.
MENU
Calculate Parking Fee
Exit
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
