← Back to List

5751번: Head or Tail ↗

Solutions

Python 3
183 B | 183 chars
while True:
    a = int(input())
    if a == 0:
        break
    L = list(map(int,input().split()))
    print("Mary won {} times and John won {} times".format(L.count(0),L.count(1)))