Advertisement
aneliabogeva

Salary

May 20th, 2019
161
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.55 KB | None | 0 0
  1. n = int(input())
  2. salary = int(input())
  3.  
  4. for i in range(0, n):
  5. site = input()
  6. if site =='Facebook':
  7. salary -= 150
  8. if salary <= 0:
  9. print(f"You have lost your salary.")
  10. break
  11. elif site == "Instagram":
  12. salary -= 100
  13. if salary <= 0:
  14. print(f"You have lost your salary.")
  15. break
  16. elif site == "Reddit":
  17. salary -= 50
  18. if salary <= 0:
  19. print(f"You have lost your salary.")
  20. break
  21.  
  22. if salary > 0:
  23. print(int(salary))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement