Advertisement
Guest User

Untitled

a guest
Jan 21st, 2020
121
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.60 KB | None | 0 0
  1. purchase_amt = int(input("Enter purchase amount (Php): "))
  2.  
  3.  
  4. if purchase_amt >= 2000:
  5.     discount = purchase_amt * 0.2
  6.     print("You have a discount of {0} pesos.".format(discount))
  7.     print("Your total payable amount is {0} pesos.".format(purchase_amt - discount))
  8. elif 1000 < purchase_amt < 2000:
  9.     discount = purchase_amt * 0.1
  10.     print("You have a discount of {0} pesos.".format(discount))
  11.     print("Your total payable amount is {0} pesos.".format(purchase_amt - discount))
  12. else:
  13.     print("You have no discount.")
  14.     print("Your total payable amount is {0} pesos".format(purchase_amt))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement