Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- imeOtbor = input()
- izigraniMachove = int(input())
- obshtoVkaraniGolove = 0
- obshtoPolucheniGolove = 0
- tochki = 0
- pobedi = 0
- if (izigraniMachove != 0):
- for mach in range(izigraniMachove):
- vkaraniGolove = int(input())
- polucheniGolove = int(input())
- obshtoVkaraniGolove += vkaraniGolove
- obshtoPolucheniGolove += polucheniGolove
- if (vkaraniGolove > polucheniGolove):
- pobedi += 1
- tochki += 3
- elif (vkaraniGolove == polucheniGolove):
- tochki += 1
- elif (polucheniGolove > vkaraniGolove):
- tochki += 0
- razlika = obshtoVkaraniGolove - obshtoPolucheniGolove
- if (obshtoVkaraniGolove >= obshtoPolucheniGolove):
- print(f"{imeOtbor} has finished the group phase with {tochki} points.")
- print(f"Goal difference: {razlika}.")
- elif(obshtoPolucheniGolove > obshtoVkaraniGolove):
- print(f"{imeOtbor} has been eliminated from the group phase.")
- print(f"Goal difference: {razlika}.")
Advertisement
Add Comment
Please, Sign In to add comment