Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- budget = int(input())
- havlia = float(input())
- discount = int(input())
- umbrella = havlia * (2 / 3)
- flip_flops = umbrella * 0.75
- bag = (flip_flops + havlia) * (1 / 3)
- total = (havlia + umbrella + flip_flops + bag) * (1 - discount / 100)
- if budget >= total:
- print(f"Annie's sum is {total:.2f} lv. She has {(budget - total):.2f} lv. left.")
- else:
- print(f"Annie's sum is {total:.2f} lv. She needs {(total - budget):.2f} lv. more.")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement