Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.
Yes, this is an assignment and would like some input or advice before i proceed to do this. I will be using an array set up for this correct? And if there are any more points you guys could provide me with that would be great! Thanks for reading this and spending your time helping me! I really appreciate it!
A parking garage has 10 customers daily. The garage charges a $2.00 minimum fee to park up to two hours. The garage charges an addition 50 cents per hour for each hour (or part of an hour) over two hours. The maximum charge for any given 24-hour period is $8.00. All cars are gone by midnight. Write a program to calculate and print a summary of the charges for a day. For input the program will read the hours of usage for each of the 10 cars. The program will print the results in the form of a table in a neat format, as shown below.
Enter the hours parked for car 1: 1.5
Enter the hours parked for car 2: 4.1
Enter the hours parked for car 3: 2.0
Enter the hours parked for car 10: 0.5
Total Hours 24.6
Total Charge 43.50
0 · ·