Harryxun/testdata huggingface dataset:
Buggy python submission (verdict: Time Limit Exceeded):
N = int(input())
a = list(map(int, input().split()))

cnt = 0
while True:
    Flag = True
    for i in range(N):
        if a[i]%2 == 1 or not Flag:
            a[i] *= 3
        else:
            Flag = False
            a[i] //= 2
    if Flag:
        break
    else:
        cnt += 1
print(cnt)

Fixed submission:
N = int(input())
a = list(map(int, input().split()))

cnt = 0
for i in range(N):
    if a[i]%2 == 1:
        continue
    else:
        while True:
            if a[i]%2 == 1:
                break
            else:
                a[i] //= 2
                cnt += 1
print(cnt)
Buggy python submission (verdict: Runtime Error):
import math
n=int(input())
dp=[math.inf for _ in range(n+1)]
dp[0]=0
for i in range(n):
    power=1
    while i+power <= n:
        dp[i+power] = min(dp[i+power],dp[i]+1)
        power*=6
    power=1
    while i+power <= n:
        dp[i+power] = min(dp[i+power],dp[i]+1)
        power*=9
print(dp[n])

Fixed submission:
n=int(input())
dp=[float("inf") for _ in range(n+1)]
dp[0]=0
for i in range(n):
    power=1
    while i+power <= n:
        dp[i+power] = min(dp[i+power],dp[i]+1)
        power*=6
    power=1
    while i+power <= n:
        dp[i+power] = min(dp[i+power],dp[i]+1)
        power*=9
print(dp[n])

Buggy python submission (verdict: Runtime Error):
import math
n=int(input())
dp=[math.inf]*(n+1)
dp[0]=0
for i in range(n):
    power=1
    while i+power <= n:
        dp[i+power] = min(dp[i+power],dp[i]+1)
        power*=6
    power=1
    while i+power <= n:
        dp[i+power] = min(dp[i+power],dp[i]+1)
        power*=9
print(dp[n])

Fixed submission:
n=int(input())
dp=[float("inf") for _ in range(n+1)]
dp[0]=0
for i in range(n):
    power=1
    while i+power <= n:
        dp[i+power] = min(dp[i+power],dp[i]+1)
        power*=6
    power=1
    while i+power <= n:
        dp[i+power] = min(dp[i+power],dp[i]+1)
        power*=9
print(dp[n])
Buggy python submission (verdict: Time Limit Exceeded):
N = int(input())
S = list(input())
L = 0
R = S.count('E')
ans = L + R
for i in range(1, N):
    L = S[:i].count('W')
    R = S[i:].count('E')
    ans = min(ans, L+R)
print(ans)

Fixed submission:
N = int(input())
S = list(input())
L = 0
R = S.count('E')
ans = L + R
for i in range(0, N):
    if S[i] == 'E':
        R -= 1
        R = max(0, R)
        ans = min(ans, L+R)
    else:
        L += 1
print(ans)
Buggy python submission (verdict: Runtime Error):
x=int(input())
c=1
for b in range(1,x):
    for p in rangenge(2,x):
        if b**p<=x:c=max(c,b**p)
        else:break
print(c)

Fixed submission:
x=int(input())
c=1
for b in range(1,x):
    for p in range(2,x):
        if b**p<=x:c=max(c,b**p)
        else:break
print(c)
Buggy python submission (verdict: Time Limit Exceeded):
from itertools import combinations
N = int(input())
A = list(map(int, input().split()))
memo = [0]*(N+1)
for i in range(1, N+1):
    memo[i] = memo[i-1] + A[i-1]

cnt = 0
for c in combinations(memo, 2):
    if c[0] == c[1]:
        cnt += 1

print(cnt)

Fixed submission:
from collections import Counter
from math import factorial

N = int(input())
A = list(map(int, input().split()))
memo = [0]*(N+1)
for i in range(1, N+1):
    memo[i] = memo[i-1] + A[i-1]

cnt = 0
C = Counter(memo)

for c in C.values():
    if c > 1:
        cnt += (factorial(c)/(2*factorial(c-2)))

print(int(cnt))
Buggy python submission (verdict: Time Limit Exceeded):
N = int(input())
x = list(map(int, input().split()))

for i in range(N):
    X = sorted(x[:i] + x[i+1:])
    print(X[(N-1)//2])


Fixed submission:
N = int(input())
x = list(map(int, input().split()))
sx = sorted(x)
a = sx[N//2-1]
b = sx[N//2]

for c in x:
    if c <= a:
        print(b)
    else:
        print(a)
Buggy python submission (verdict: Runtime Error):
a,b,k=map(int,input().split())
R=list(range(a,b+1))
for x in sorted(set(R[:k])|set(R[-k:])):
    print(x)

Fixed submission:
a,b,k=map(int,input().split())
R=range(a,b+1)
for x in sorted(set(R[:k])|set(R[-k:])):
    print(x)

Buggy python submission (verdict: Time Limit Exceeded):
a,b,k=map(int,input().split())
R=[i for i in range(a,b+1)]
for x in sorted(set(R[:k])|set(R[-k:])):
    print(x)

Fixed submission:
a,b,k=map(int,input().split())
R=range(a,b+1)
for x in sorted(set(R[:k])|set(R[-k:])):
    print(x)
Buggy python submission (verdict: Runtime Error):
N, M = map(int, input().split())
G = [[1]*M for _ in range(N)]

x = (-1, 0, 1)
y = (-1, 0, 1)
for i in range(N):
    for j in range(M):
        for dx in x:
            for dy in y:
                if 0 <= i+dy <= N-1 and 0 <= j+dx <= M-1:
                    G[i+dy][j+dx] *= -1

ans = 0
for g in G:
    ans += g.count(-1)
print(ans)

Fixed submission:
N, M = map(int, input().split())
if N <= 2 or M <= 2:
    if N == 1 and M ==1:
        ans = 1
    elif N == 1 or M == 1:
        ans = max(N-2, M-2)
    else:
        ans = 0
else:
    ans = (N-2)*(M-2)
print(ans)
Buggy python submission (verdict: Runtime Error):
a,b = map(int,input().split())
s = input()

if s.count('-') == 1:
    s = s.split('-')
    if len('-'.join(s)) == a+b+1 and len(s[0])== a and len(s[2]) == b:
        print('Yes')
    else:
        print('No')
else:
    print('No')

Fixed submission:
a,b = map(int,input().split())
s = input()

if s.count('-') == 1:
    S = s.split('-')
    if len('-'.join(S)) == a+b+1 and len(S[0]) == a and len(S[1]) == b:
        print('Yes')
    else:
        print('No')
else:
    print('No')

Buggy python submission (verdict: Runtime Error):
a,b = map(int,input().split())
s = input()
if s[3] == '-' and len(s) == a+b+1:
    print('Yes')
else:
    print('No')

Fixed submission:
a,b = map(int,input().split())
s = input()

if s.count('-') == 1:
    S = s.split('-')
    if len('-'.join(S)) == a+b+1 and len(S[0]) == a and len(S[1]) == b:
        print('Yes')
    else:
        print('No')
else:
    print('No')
Buggy python submission (verdict: Time Limit Exceeded):
Q = int(input())
memo = [0]*(10**5+1)
def eratos2():
    primes = []
    for i in range(2, 10**4):
        flag = True
        for p in primes:
            if i%p == 0:
                flag = False
        if flag:
            primes.append(i)
    return primes
D = eratos2()

for i in range(1, 10**5+1):
    if i in D and (i+1)//2 in D:
        memo[i] = memo[i-1] + 1
    else:
        memo[i] = memo[i-1]

for _ in range(Q):
    l, r = map(int, input().split())
    print(memo[r+1]-memo[l-1])

Fixed submission:
Q = int(input())
memo = [0]*(10**5+1)

def is_prime(N):
    prime = [True for _ in range(N)]
    prime[1] = False
    for i in range(2, N):
        if not prime[i]:
            continue
        j = i+i
        while j<N:
            prime[j] = False
            j += i
    return prime

prime = is_prime(10**5+1)

for i in range(1, 10**5+1):
    if prime[i] and prime[(i+1)//2]:
        memo[i] = memo[i-1] + 1
    else:
        memo[i] = memo[i-1]

for _ in range(Q):
    l, r = map(int, input().split())
    print(memo[r+1]-memo[l-1])
Buggy python submission (verdict: Runtime Error):
a=int(input())
b=int(input())
ans= (a+b)//2 if (a+b)%2 == 0 else (a+b)//2+1
print(ans)

Fixed submission:
a,b=map(int,input().split())
ans= (a+b)//2 if (a+b)%2 == 0 else (a+b)//2+1
print(ans)
Buggy python submission (verdict: Runtime Error):
a,b,c=map(int,input().split())
print(a+b+c)

Fixed submission:
l=[int(i) for i in input()]
print(sum(l))

Buggy python submission (verdict: Runtime Error):
a,b,c=map(int,input().split())
print(sum(a,b,c))

Fixed submission:
l=[int(i) for i in input()]
print(sum(l))
Buggy python submission (verdict: Runtime Error):
print(sum(1-eval(input().replace(' ','-')), for _ in range(int(input())))

Fixed submission:
print(sum(1-eval(input().replace(' ', '-')) for _ in range(int(input()))))
Buggy python submission (verdict: Time Limit Exceeded):
from collections import deque
N = int(input())
ans = deque([])
for _ in range(N):
    a = int(input())
    if a not in ans:
        ans.append(a)
    else:
        ans.remove(a)
print(len(ans))

Fixed submission:
from collections import Counter
N = int(input())
ans = Counter([int(input()) for _ in range(N)])
cnt = 0
for c in ans.values():
    if c%2 == 1:
        cnt += 1
print(cnt)

Buggy python submission (verdict: Time Limit Exceeded):
N = int(input())
ans = []
for _ in range(N):
    a = int(input())
    if a not in ans:
        ans.append(a)
    else:
        ans.remove(a)
print(len(ans))

Fixed submission:
from collections import Counter
N = int(input())
ans = Counter([int(input()) for _ in range(N)])
cnt = 0
for c in ans.values():
    if c%2 == 1:
        cnt += 1
print(cnt)

Buggy python submission (verdict: Runtime Error):
c11, c12, c13 = map(int, input().split())
c21, c22, c23 = map(int, input().split())
c31, c32, c33 = map(int, input().split())

if not (c12-c11 == c22-c21 == c32-c31):
    print("No")
    quit()
if not (c13-c12 == c23-c22 == c33-c32):
    print("No")
    quit()
if not (c21-c11 == c22-c12 == c23-c13):
    print("No")
    quit()
if not (c31-c21 == c32-c22 == c33-c23):
    print("No")
    quit()

print("Yes")

Fixed submission:
from collections import Counter
N = int(input())
ans = Counter([int(input()) for _ in range(N)])
cnt = 0
for c in ans.values():
    if c%2 == 1:
        cnt += 1
print(cnt)
Buggy python submission (verdict: Runtime Error):
N = int(input())
A = list(map(int, input().split()))
maxim = max(A)
counter = [0]*(maxim+1)
dif = [-1, 0, 1]
for a in A:
    for d in dif:
        if a == 0:
            counter[0] += 1
            counter[1] += 1
            break
        elif a == maxim:
            counter[maxim-1] += 1
            counter[maxim] += 1
        else:
            counter[a+d] += 1
print(max(counter))

Fixed submission:
N = int(input())
A = list(map(int, input().split()))
maxim = max(A)
counter = [0]*(maxim+1)
dif = [-1, 0, 1]
for a in A:
    for d in dif:
        i = a + d
        if i < 0 or maxim < i:
            continue
        else:
            counter[i] += 1
print(max(counter))

Buggy python submission (verdict: Runtime Error):
N = int(input())
A = list(map(int, input().split()))
counter = [0]*(max(A)+1)
dif = [-1, 0, 1]
for a in A:
    for d in dif:
        counter[a+d-1] += 1
print(max(counter))

Fixed submission:
N = int(input())
A = list(map(int, input().split()))
maxim = max(A)
counter = [0]*(maxim+1)
dif = [-1, 0, 1]
for a in A:
    for d in dif:
        i = a + d
        if i < 0 or maxim < i:
            continue
        else:
            counter[i] += 1
print(max(counter))
Buggy python submission (verdict: Runtime Error):
N = int(input())
P = list(map(int, input().split()))

ans = 0
cnt = 0
flag = 1
while flag:
    flag = 0
    if cnt == N-1:
        break
    for i in range(cnt, N):
        if P[i] == i+1:
            P[i], P[i+1] = P[i+1], P[i]
            ans += 1
            flag = 1
        else:
            cnt += 1

print(ans)

Fixed submission:
N = int(input())
P = list(map(int, input().split()))

ans = 0

for i in range(N):
    if P[i] != i+1:
        continue
    if i+1 < N and P[i] != i+2 or i == 0:
        P[i], P[i+1] = P[i+1], P[i]
        ans += 1
    else:
        P[i], P[i-1] = P[i-1], P[i]
        ans += 1

print(ans)

Buggy python submission (verdict: Runtime Error):
N = int(input())
P = list(map(int, input().split()))

ans = 0
cnt = 0
flag = 1
while flag:
    flag = 0
    for i in range(cnt, N):
        if P[i] == i+1:
            P[i], P[i+1] = P[i+1], P[i]
            ans += 1
            flag = 1
        else:
            cnt += 1

print(ans)

Fixed submission:
N = int(input())
P = list(map(int, input().split()))

ans = 0

for i in range(N):
    if P[i] != i+1:
        continue
    if i+1 < N and P[i] != i+2 or i == 0:
        P[i], P[i+1] = P[i+1], P[i]
        ans += 1
    else:
        P[i], P[i-1] = P[i-1], P[i]
        ans += 1

print(ans)
Buggy python submission (verdict: Runtime Error):
S = list(S)
print('yes' if len(set(S)) == len(S) else 'no')

Fixed submission:
S = list(input())
print('yes' if len(set(S)) == len(S) else 'no')
Buggy python submission (verdict: Runtime Error):
a,b,c=map(int,input().split())
print('YES' if b-a==c-b else 'NO)

Fixed submission:
a,b,c=map(int,input().split())
print('YES' if b-a==c-b else 'NO')
Buggy python submission (verdict: Runtime Error):
N, M = map(int, input().split())
ab = []
cd = []
for _ in range(N):
    a, b = map(int, input().split())
    ab.append([a, b])
for _ in range(N):
    c, d = map(int, input().split())
    cd.append([c, d])

for a, b in ab:
    near = 10**32
    for i, n in enumerate(cd):
        tmp = abs(a-n[0])+abs(b-n[1])
        if near == tmp:
            continue
        near = min(near, tmp)
        if near == tmp:
            ans = i + 1
    print(ans)

Fixed submission:
N, M = map(int, input().split())

ab = []
cd = []
for _ in range(N):
    a, b = map(int, input().split())
    ab.append([a, b])
for _ in range(M):
    c, d = map(int, input().split())
    cd.append([c, d])

for a, b in ab:
    near = 10**32
    for i, n in enumerate(cd):
        tmp = abs(a-n[0])+abs(b-n[1])
        if near == tmp:
            continue
        near = min(near, tmp)
        if near == tmp:
            ans = i + 1
    print(ans)

Buggy python submission (verdict: Runtime Error):
N, M = map(int, input().split())
ab = []
cd = []
for _ in range(N):
    a, b = map(int, input().split())
    ab.append([a, b])
for _ in range(N):
    c, d = map(int, input().split())
    cd.append([c, d])

for a, b in ab:
    near = 10**16
    for i, n in enumerate(cd):
        tmp = abs(a-n[0])+abs(b-n[1])
        if near == tmp:
            continue
        near = min(near, tmp)
        if near == tmp:
            ans = i + 1
    print(ans)

Fixed submission:
N, M = map(int, input().split())

ab = []
cd = []
for _ in range(N):
    a, b = map(int, input().split())
    ab.append([a, b])
for _ in range(M):
    c, d = map(int, input().split())
    cd.append([c, d])

for a, b in ab:
    near = 10**32
    for i, n in enumerate(cd):
        tmp = abs(a-n[0])+abs(b-n[1])
        if near == tmp:
            continue
        near = min(near, tmp)
        if near == tmp:
            ans = i + 1
    print(ans)
Buggy python submission (verdict: Time Limit Exceeded):
n=int(input())
ans=1
for i in range(1,n+1):
    ans*=i
print(ans%(10**9+7))

Fixed submission:
n=int(input())
ans=1
for i in range(1,n+1):
    ans*=i
    ans=ans%(10**9+7)
print(ans)
Buggy python submission (verdict: Runtime Error):
if a >= 3200:
  print(s)
else:
  print('red')

Fixed submission:
a = int(input())
s = input()

if a >= 3200:
  print(s)
  
else:
  print("red")
Buggy python submission (verdict: Runtime Error):
N = input()
A = map(int, input().split())

print("{.16g}".format(sum(1/x for x in A)))

Fixed submission:
N = int(input())
A = map(int, input().split())
print('{:.16g}'.format(1 / sum(1 / x for x in A)))

Buggy python submission (verdict: Runtime Error):
N = input()
A = map(int, input().split())

print({:16g}.format(1/sum(1/x for x in A)))

Fixed submission:
N = int(input())
A = map(int, input().split())
print('{:.16g}'.format(1 / sum(1 / x for x in A)))
Buggy python submission (verdict: Runtime Error):
import sys
import math

sys.setrecursionlimit(10**6)



def put_que(n):
    global tmp, tree
    if n in tmp:
        return
    que.append(n)
    tmp.add(n)
    for i in tree[n]:
        put_que(i)


def set_answer(n, i):
    global tree, answer
    # print(n, '-',i, tree[n])
    answer.append('{} {}'.format(n, i))
    tree[i].remove(n)

def search(n):
    global tree, que, answer

    if len(tree[n]) & 1:
        i = tree[n].pop()
        answer.append('{} {}'.format(i, n))
        tree[i].remove(n)

        j = tree[i].pop()
        answer.append('{} {}'.format(i, j))
        tree[j].remove(i)
    
    while len(tree[n]) > 0:
        i = tree[n].pop()
        answer.append('{} {}'.format(n, i))
        tree[i].remove(n)

def main():
    global tree, que, answer

    N, m = list(map(int, input().split()))
    tree = {i+1 : set() for i in range(N)}

    for _ in range(m):
        i, j = list(map(int, input().split()))
        tree[i].add(j)
        tree[j].add(i)

    if m % 2 == 1:
        print(-1)
        return

    # print(tree)
    put_que(1)
    for n in reversed(que):
        search(n)
            
    print(*answer, sep="\n")


if __name__ == "__main__":
    tmp = set()
    que = []
    answer = []
    main()



Fixed submission:
def main():
    N = int(input())
    V = list(map(int, input().split()))

    n = 0
    for i in V:
        n = i ^ n
    if n == 0:
        print('Yes')
    else:
        print('No')

if __name__ == "__main__":
    main()

Buggy python submission (verdict: Runtime Error):
def main():
    global tree, que, answer

    N, m = list(map(int, input().split()))
    tree = {i+1 : set() for i in range(N)}

    for _ in range(m):
        i, j = list(map(int, input().split()))
        tree[i].add(j)
        tree[j].add(i)

    if m % 2 == 1:
        print('-1')
        return

    print(*answer, sep="\n")


if __name__ == "__main__":
    tmp = set()
    que = []
    answer = []
    main()


Fixed submission:
def main():
    N = int(input())
    V = list(map(int, input().split()))

    n = 0
    for i in V:
        n = i ^ n
    if n == 0:
        print('Yes')
    else:
        print('No')

if __name__ == "__main__":
    main()
Buggy python submission (verdict: Time Limit Exceeded):
N = int(input())
a = list(map(int, input().split()))

S = sum(a)
arr = [abs(S - 2*sum(a[:i]))   for i in range(1,N)]

print(min(arr))

Fixed submission:
N = int(input())
a = list(map(int, input().split()))

S = sum(a)
_min  = 10000000000000000000
x = 0
for i in range(0,N-1):
  x += a[i]
  tmp = abs(S - 2*x)
  if tmp < _min:
    _min = tmp

print(_min)

Buggy python submission (verdict: Time Limit Exceeded):
N = int(input())
a = list(map(int, input().split()))

arr = [abs(sum(a[:i]) - sum(a[i:]))  for i in range(1,N)]

print(min(arr))

Fixed submission:
N = int(input())
a = list(map(int, input().split()))

S = sum(a)
_min  = 10000000000000000000
x = 0
for i in range(0,N-1):
  x += a[i]
  tmp = abs(S - 2*x)
  if tmp < _min:
    _min = tmp

print(_min)

Buggy python submission (verdict: Time Limit Exceeded):
N = int(input())
a = list(map(int, input().split()))

min = 1000000000000000000000
for i in range(1,N):
  tmp = abs(sum(a[:i]) - sum(a[i:])) 
  if min > tmp:
    min = tmp

print(min)

Fixed submission:
N = int(input())
a = list(map(int, input().split()))

S = sum(a)
_min  = 10000000000000000000
x = 0
for i in range(0,N-1):
  x += a[i]
  tmp = abs(S - 2*x)
  if tmp < _min:
    _min = tmp

print(_min)
Buggy python submission (verdict: Runtime Error):
n=int(input())
def alpha2num(alpha):
    num=0
    for index,item in enumerate(list(alpha)):
        num+=pow(26,len(alpha)-index-1)*(ord(item)-ord("A")+1)
    return num
if 1<=n<=26:
    n=n
    print(alpha2num(n))
elif 27<=n<=702:
    n-=26
    print(alpha2num(n))
elif 703<=n<=18278:
    n-=702
    print(alpha2num(n))
elif 18279<=n<=475254:
    n-=18278
    print(alpha2num(n))
else:
    n-=475254
    print(alpha2num(n))

Fixed submission:
n=int(input())
def alpha2num(alpha):
    if alpha<=26:
        return chr(64+alpha)
    elif alpha%26==0:
        return alpha2num(alpha//26-1)+chr(90)
    else:
        return alpha2num(alpha//26)+chr(64+alpha%26)
print(alpha2num(n).lower())
Buggy python submission (verdict: Runtime Error):
S=input()
K=int(input())
if len(S)<=K:
    print(S)
else:
    print(S[:K]+"...")

Fixed submission:
K=int(input())
S=input()
if len(S)<=K:
    print(S)
else:
    print(S[:K]+"...")

Buggy python submission (verdict: Runtime Error):
S=str(input())
K=int(input())
if len(S)<=K:
    print(S)
else:
    print(S[0:K]+"...")

Fixed submission:
K=int(input())
S=input()
if len(S)<=K:
    print(S)
else:
    print(S[:K]+"...")

Buggy python submission (verdict: Runtime Error):
S=input()
K=input()
if len(S)<=K:
    print(S)
else:
    print(S[:K]+"...")

Fixed submission:
K=int(input())
S=input()
if len(S)<=K:
    print(S)
else:
    print(S[:K]+"...")

Buggy python submission (verdict: Runtime Error):
S=str(input())
K=int(input())
if len(S)<=K:
    print(S)
else:
    print(S[:K]+"...")

Fixed submission:
K=int(input())
S=input()
if len(S)<=K:
    print(S)
else:
    print(S[:K]+"...")
Buggy python submission (verdict: Runtime Error):
if T[:-1]==S:    
    print("Yes")
else:
    print("No")

Fixed submission:
s=input()
t=input()
if t[:-1]==s:
    print("Yes")
else:
    print("No")

Buggy python submission (verdict: Runtime Error):
if T[:-1]==S:    
    print("Yes")
else:
    print("No")

Fixed submission:
s=input()
t=input()
if t[:-1]==s:
    print("Yes")
else:
    print("No")

Buggy python submission (verdict: Runtime Error):
S="".join([random.choice(string.ascii_lowercase)for i in range(a)])
print(S)

Fixed submission:
s=input()
t=input()
if t[:-1]==s:
    print("Yes")
else:
    print("No")
Buggy python submission (verdict: Runtime Error):
a,b,c,k=map(int,input().split())
n=k-a-b
if n>=0 
    print(a-n)
elif n<0 and a<=k:
    print(a)
elif n<0 and a>k:
    print(k)

Fixed submission:
a,b,c,k=map(int,input().split())
n=k-a-b
if n>=0: 
    print(a-n)
elif n<0 and a<=k:
    print(a)
elif n<0 and a>k:
    print(k)

Buggy python submission (verdict: Runtime Error):
a,b,c,k=map(int,input().split())
n=k-a-b
if n>=0 
    print(a-n)
elif n<0 and a<=k:
    print(a)
else:
    print(k)

Fixed submission:
a,b,c,k=map(int,input().split())
n=k-a-b
if n>=0: 
    print(a-n)
elif n<0 and a<=k:
    print(a)
elif n<0 and a>k:
    print(k)
Buggy python submission (verdict: Runtime Error):
n=int(input())
li=[]
for si in n:
    si=input()
    li.append(si)
print(len(set(li)))

Fixed submission:
n=int(input())
li=[]
for si in range(n):
    si=input()
    li.append(si)
print(len(set(li)))
Buggy python submission (verdict: Runtime Error):
n,m=map(int,input().split())
li=[]
ai=map(int,input().split())
li.append(ai)
k=sum(li)
if k<=n:
    print(n-k)
else:
    print("-1")

Fixed submission:
n,m=map(int,input().split())
ai=list(map(int,input().split()))
k=sum(ai)
if k<=n:
    print(n-k)
else:
    print("-1")

Buggy python submission (verdict: Runtime Error):
n,m=map(int,input().split())
li=[]
for ai in range(m):
    ai=int(input())
    li.append(ai)
k=sum(li)
if k<=n:
    print(m-k)
else:
    print("-1")

Fixed submission:
n,m=map(int,input().split())
ai=list(map(int,input().split()))
k=sum(ai)
if k<=n:
    print(n-k)
else:
    print("-1")

Buggy python submission (verdict: Runtime Error):
n,m=map(int,input().split())
li=[]
for ai in range(m):
    ai=map(int,input().split())
    li.append(ai)
k=sum(li)
if k<=n:
    print(m-k)
else:
    print("-1")

Fixed submission:
n,m=map(int,input().split())
ai=list(map(int,input().split()))
k=sum(ai)
if k<=n:
    print(n-k)
else:
    print("-1")

Buggy python submission (verdict: Runtime Error):
n,m=map(int,input().split())
for ai in range(m):
    ai=list(map(int,input().split())
    k=sum(ai)
if k<=n:
    print(m-k)
else:
    print("-1")

Fixed submission:
n,m=map(int,input().split())
ai=list(map(int,input().split()))
k=sum(ai)
if k<=n:
    print(n-k)
else:
    print("-1")

Buggy python submission (verdict: Runtime Error):
n,m=map(int,input().split())
for ai in range(m):
    ai=list(int(input()))
    k=sum(ai)
if k<=m:
    print(m-k)
else:
    print("-1")

Fixed submission:
n,m=map(int,input().split())
ai=list(map(int,input().split()))
k=sum(ai)
if k<=n:
    print(n-k)
else:
    print("-1")
Buggy python submission (verdict: Runtime Error):
n=int(input())
p=list(map(int,input().split()))
li=[]
for i in range(1,n):
    q=p.count(i)
    li.append(q)
nl=li.split("\n")
print(nl)

Fixed submission:
n=int(input())
p=list(map(int,input().split()))
m=[0]*n
for i in p:
    m[i-1]+=1
for a in m:
    print(a,"\n")