Question: I need with c + + Write a program to calculate parking cost for a vehicle considering the table below. Display the menu to the

I need with c++Write a program to calculate parking cost for a vehicle considering the table below. Display the menu to the user. Then, the program prompts the user to enter vehicle type. While the vehicle type is valid, the program will ask the user for duration in hours and calculate the parking cost for vehicles. While loop continues until the user enters a vehicle type different from the ones listed in the table.
\table[[Vehicle type (char),Rate per hour],[C or c,AED 1.5],[L or l,AED 2.5],[B or b,AED 3.5]]
C or c: car
L or 1: lorry
B or b: bus
Any other to exit
Please enter a vehicle type from the menu above: h
C or c: car
L or 1: lorry
B or b: bus
Any other to exit
Please enter a vehicle type from the menu above: c
Enter duration in hours: 4.5
The parking cost of the car is 6.75
C or c: car
L or 1: lorry
B or b: bus
Any other to exit
Please enter a vehicle type from the menu above: b
Enter duration in hours: 3.5
The parking cost of the bus is : 12.25
C or c: car
L or 1: lorry
B or b: bus
Any other to exit
Please enter a vehicle type from the menu above: d
 I need with c++Write a program to calculate parking cost for

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!