Spocoman

07. The Office

Feb 10th, 2022 (edited)
172
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.29 KB | None | 0 0
  1. lst = list(map(int, input().split(' ')))
  2. factor = int(input())
  3. lst = [x for x in lst if x * factor]
  4. happy = [x for x in lst if x >= sum(lst) / len(lst)]
  5. happy_or_not = '' if len(lst) <= len(happy) * 2 else ' not'
  6.  
  7. print(f'Score: {len(happy)}/{len(lst)}. Employees are{happy_or_not} happy!')
  8.  
Add Comment
Please, Sign In to add comment