Question: Write a Python program to simulate giving change for a purchase. The program should input the price of the item purchased. Then it should compute
Write a Python program to simulate giving change for a purchase. The program should input the price of the item purchased. Then it should compute the HST (15%) and report the total amount due (price + HST). Next, the program should input a payment from the customer (you can assume this at least as large as what is owed). Knowing both the total owed and the customer payment, the program can figure out what change to return. The output should report the number of toonies, loonies, quarters, dimes, nickels and pennies to be returned to the customer. Of course, the number of coins returned should be minimal.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
