Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- command = input()
- days_count = 1
- meters_reached = 5364
- while command != "END":
- count_meters = int(input())
- if command == "Yes":
- days_count += 1
- if days_count > 5 or meters_reached >= 8848:
- break
- meters_reached += count_meters
- if days_count > 5 or meters_reached >= 8848:
- break
- command = input()
- if meters_reached >= 8848:
- print(f"Goal reached for {days_count} days!")
- else:
- print("Failed!")
- print(f"{meters_reached}")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement