Advertisement
Dimitar46

8.Lunch Break

Jun 9th, 2022
593
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.46 KB | None | 0 0
  1. import math
  2.  
  3. serial = input()
  4. episode = int(input())
  5. breakTime = int(input())
  6. timeForLunch = breakTime * 1 / 8
  7. timeForBreak = breakTime * 1 / 4
  8. leftTime = breakTime - timeForLunch - timeForBreak
  9. if leftTime >= episode:
  10.     print(f'You have enough time to watch {serial} and left with {math.ceil(leftTime - episode):.0f} minutes free time.')
  11. else:
  12.     print(f"You don't have enough time to watch {serial}, you need {math.ceil(episode-leftTime):.0f} more minutes.")
  13.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement