CSIS 130 Programs
Spring 08
Assgnment #2
- Due Due 2/7 @ classtime, Write
a program that accepts a sales amount (in dollars) and an amount tendered
(in dollars) and then displays to the screen the change (in dollars) along
with only the correct denominations of money returned. Your output needs to
be grammatically correct. For example 2-Quarters vs. 1-Quarter. Your progranm
should error proof for invalid money amounts. A sample run is listed below.
The blue text indicates user
input.
Welcome to my Change Program
Please enter the sales price (xx.xx): $3.46
Please enter the amount tendered (xx.xx): $2.00
I'm sorry you did not give enough money to pay for the item.
Please re-enter the amount tendered. It must be at least $3.46 (xx.xx): $5.00
Your change is: $1.54
You will recieve:
1 - Dollar Bill
2 - Quarters
4 - Pennies