Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- number_sea = int(input())
- number_mountain = int(input())
- profit = 0
- while number_mountain > 0 or number_sea > 0:
- package = input()
- if package == "Stop":
- break
- elif package == "sea":
- number_sea -= 1
- if number_sea >= 0:
- profit += 680
- elif package == "mountain":
- number_mountain -= 1
- if number_mountain >= 0:
- profit += 499
- if number_sea <= 0 and number_mountain <= 0:
- print(f"Good job! Everything is sold.")
- print(f"Profit: {profit} leva.")
Add Comment
Please, Sign In to add comment