Question 1: A scooter/motorcycle stand charges the following rates for the parking: Hours Rate per hour First 5 hours Rs. 5.00 For the next 5 hours Rs. 3.00 Above that Rs. 2.50 Write a program to input the number of hours for which a 2-wheeler is parked. Calculate and print the parking charges to be paid by the customer.
Answers
Answered by
1
aajkal kamal kahan pseudo paksh trial lailatul Parker
Answered by
2
Answer:
CLS
REM PARKING STAND CHARGES
INPUT "ENTER THE NUMBER OF HOURS"; N
IF N >= 1 AND N <= 5 THEN
B = N * 5
ELSEIF N > 5 AND N <= 10 THEN
B = 5 * 5 + ((N - 5) * 3)
ELSEIF N > 10 THEN
B = 5 * 5 + 5 * 3 + ((N - 10) * 2.5)
END IF
PRINT "THE TOTAL BILL"; B
END
Since you did not mention any Program-Coding language, I coded it in the simplest Language (Qbasic)
Thanks & Regards
Similar questions