Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- prompt = "\nPer favore inserisci la tua eta'."
- prompt += "\nInserisci 'quit' quando hai finito. "
- answer = "Your price is: $"
- while True:
- age = input(prompt)
- if age == 'quit':
- break
- age = int(age)
- if age < 3:
- price = 0
- elif age < 13:
- price = 10
- else:
- price = 15
- print(f"{answer}{price}")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement