Hi, the program is this:
Discount problem:
Available deals:
10% off the total price when you buy $200 or more
15% off the total price when you buy $500 or more
20% off the total price when you buy $1000 or more
Write a program that outputs the value, price and savings for a customer.
Assume that the customer will get the best deal for what they buy.
Ex:
Enter the total purchased: $1500.00
Total value of goods: $1500.00
Total amount spent: $1200.00
Savings on purchase: $300.00
I don't really get how to do this program, just beginning but please don't post anything really difficult. Only learned basics and if statement and for-loop.
My code right now is:
purchased = float(raw_input("Enter the total purchased: $"))
if purchased >= 200:
savings = purchased / 0.10
elif purchased >= 500:
savings = purchased / 0.15
elif purchased >= 1000:
savings = purchased / 0.20
print "Total value of goods: $%.2f" % purchased
I don't understand how to continue, any help fast appreciated, thanks.