Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- price = 800
- print("Hello, thanks for purchasing this new phone")
- user_answer = input("Do you have good credit? ")
- if user_answer == "yes":
- down_payment = 0.0625 * price
- has_goodcredit = f"downpayment: ${(price * .1)}"
- print(f"total: ${down_payment + price}")
- print(f"downpayment: ${down_payment}")
- elif user_answer == "no":
- down_payment = 0.2 * price
- has_badcredit = f"downpayment: ${(price * .2)}"
- print(f"total: ${down_payment + price}")
- print(f"downpayment: ${down_payment}")
- else:
- print("Error: Answer must be yes or no")
- print("Lets try that again")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement