Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- command = input()
- hettrick_made = 0
- the_best_player = ''
- goals_best_player = 0
- while command != "END":
- name = command
- goals = int(input())
- if goals > goals_best_player:
- goals_best_player = goals
- the_best_player = name
- if goals >= 3 and goals < 10:
- hettrick_made += 1
- elif goals >= 10:
- goals_best_player = goals
- the_best_player = name
- break
- command = input()
- print(f"{the_best_player} is the best player!")
- if hettrick_made > 0:
- print(f"He has scored {goals_best_player} goals and made a hat-trick !!!")
- elif goals_best_player >= 10:
- print(f"He has scored {goals_best_player} goals and made a hat-trick !!!")
- else:
- print(f"He has scored {goals_best_player} goals.")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement