Advertisement
ydpetkov

bonus_points

Jul 13th, 2022
23
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.28 KB | None | 0 0
  1. number = int(input())
  2. bonus = 0
  3.  
  4. if number <= 100:
  5. bonus = 5
  6. elif number <= 1000:
  7. bonus = number * 0.20
  8. else:
  9. bonus = number * 0.10
  10. if number % 2 == 0:
  11. bonus = bonus + 1
  12. if number % 10 == 5:
  13. bonus = bonus + 2
  14.  
  15. print(bonus)
  16. print(number + bonus)
  17.  
  18.  
  19.  
  20.  
  21.  
  22.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement