Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- command = str(input())
- goals_record = 0
- hat_trick = False
- best_player = ""
- while command != "END":
- current_player = command
- goals = int(input())
- if goals > goals_record:
- best_player = current_player
- goals_record = goals
- if goals >= 3:
- hat_trick = True
- if goals >= 10:
- break
- command = str(input())
- print(f"{best_player} is the best player!")
- if hat_trick:
- print(f"He has scored {goals_record} goals and made a hat-trick !!!")
- else:
- print(f"He has scored {goals_record} goals.")
Advertisement
Add Comment
Please, Sign In to add comment