Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- days_off = int(input())
- norm_play_tom = 30000
- work_day = 365 - days_off
- play_with_tom_work_day_years = work_day * 63
- play_with_tom_day_off_years = days_off * 127
- play_with_tom_all_of_years = play_with_tom_work_day_years + play_with_tom_day_off_years
- remaining_time = abs(norm_play_tom - play_with_tom_all_of_years)
- remaining_time_hours = remaining_time // 60
- remaining_time_minutes = remaining_time % 60
- if play_with_tom_all_of_years > norm_play_tom:
- print("Tom will run away")
- print(f"{remaining_time_hours} hours and {remaining_time_minutes} minutes more for play")
- else:
- print("Tom sleeps well")
- print(f"{remaining_time_hours} hours and {remaining_time_minutes} minutes less for play")
Advertisement
Add Comment
Please, Sign In to add comment