Harryxun/testdata huggingface dataset:
Buggy python submission (verdict: Runtime Error):
import sys

lines = sys.stdin.readlines()

num_a ,num_b, num_m = [int(v) for v in lines[0].split()]
# ----

a_list = [int(v) for v in lines[1].split()[:num_a+1]]
b_list = [int(v) for v in lines[2].split()[:num_b+1]]

# print(a_list)
# print(b_list)

result = max(a_list) + max(b_list)
# ignores = set()
for c in lines[3:num_m+3]:
    a_i, b_i, discount = map(int, c.split())
    try:
#         ignores.add((int(a_i), int(b_i)))    
        price = a_list[a_i-1] + b_list[b_i-1] - discount
        
        if price < result:
            result = price
    except IndexError:
        print('------')
        print(c)
        pass

res1 = [
    a_list[a_i-1]+b_list[b_i-1]-discount for a_i, b_i, discount in [map(int, l.split())  for l in lines[3:num_m+3]]]


res2 = [a+b for b in b_list
        for a in a_list]

print(min(min(res1), min(res2)))

Fixed submission:
import sys

lines = sys.stdin.readlines()
 
text = lines[0]

import re
if re.match(r'^(hi)+$', text):
    print('Yes')
else:
    print('No')

Buggy python submission (verdict: Runtime Error):
import sys
 
lines = sys.stdin.readlines()
num_a ,num_b, num_m = [int(v) for v in lines[0].split()]
# ----
 
a_list = [int(v) for v in lines[1].split()[:num_a+1]]
b_list = [int(v) for v in lines[2].split()[:num_b+1]]
 
# print(a_list)
# print(b_list)
 
result = max(a_list) + max(b_list)
ignores = set()
for c in lines[3:num_m+3]:
    a_i, b_i, discount = map(int, c.split())
    try:
        ignores.add((int(a_i), int(b_i)))
        
        price = a_list[a_i-1] + b_list[b_i-1] - discount
        
        if price < result:
            result = price
    except IndexError:
        print('------')
        print(c)
        pass
 
# ---
# result = max(a_list) + max(b_list)
for i, a in enumerate(a_list):
    for j, b in enumerate(b_list):
        if (i+1, j+1) not in ignores:
            price = a + b
            result = price if price < result else result
            
    
print(result)


Fixed submission:
import sys

lines = sys.stdin.readlines()
 
text = lines[0]

import re
if re.match(r'^(hi)+$', text):
    print('Yes')
else:
    print('No')
Buggy python submission (verdict: Time Limit Exceeded):
import sys

lines = sys.stdin.readlines()

# lines = test.strip().split('\n')
num_a ,num_b, num_m = [int(v) for v in lines[0].split()]
# ----

a_list = [int(v) for v in lines[1].split()[:num_a+1]]
b_list = [int(v) for v in lines[2].split()[:num_b+1]]

# print(a_list)
# print(b_list)

# result = max(a_list) + max(b_list)
# # ignores = set()
# for c in lines[3:num_m+3]:
#     a_i, b_i, discount = map(int, c.split())
#     try:
# #         ignores.add((int(a_i), int(b_i)))    
#         price = a_list[a_i-1] + b_list[b_i-1] - discount
        
#         if price < result:
#             result = price
#     except IndexError:
#         print('------')
#         print(c)
#         pass

res1 = [
    a_list[a_i-1]+b_list[b_i-1]-discount for a_i, b_i, discount in [map(int, l.split())  for l in lines[3:num_m+3]]]


res2 = [a+b for b in b_list
        for a in a_list]

print(min(min(res1), min(res2)))

Fixed submission:
import sys

lines = sys.stdin.readlines()

# lines = test.strip().split('\n')
num_a ,num_b, num_m = [int(v) for v in lines[0].split()]
# ----

a_list = [int(v) for v in lines[1].split()[:num_a+1]]
b_list = [int(v) for v in lines[2].split()[:num_b+1]]

res1 = [
    a_list[a_i-1]+b_list[b_i-1]-discount for a_i, b_i, discount in [
        map(int, l.split())  for l in lines[3:num_m+3]
    ]
]

res2 = min(a_list) + min (b_list)

print(min(min(res1), res2))

Buggy python submission (verdict: Time Limit Exceeded):
import sys
 
lines = sys.stdin.readlines()
num_a ,num_b, num_m = [int(v) for v in lines[0].split()]
# ----
 
a_list = [int(v) for v in lines[1].split()[:num_a+1]]
b_list = [int(v) for v in lines[2].split()[:num_b+1]]
 
# print(a_list)
# print(b_list)
 
result = max(a_list) + max(b_list)
ignores = set()
for c in lines[3:num_m+3]:
    a_i, b_i, discount = map(int, c.split())
    try:
        ignores.add((int(a_i), int(b_i)))
        
        price = a_list[a_i-1] + b_list[b_i-1] - discount
        
        if price < result:
            result = price
    except IndexError:
        print('------')
        print(c)
        pass
 
# ---
# result = max(a_list) + max(b_list)
for i, a in enumerate(a_list):
    for j, b in enumerate(b_list):
        if (i+1, j+1) not in ignores:
            price = a + b
            result = price if price < result else result
            
print(result)

Fixed submission:
import sys

lines = sys.stdin.readlines()

# lines = test.strip().split('\n')
num_a ,num_b, num_m = [int(v) for v in lines[0].split()]
# ----

a_list = [int(v) for v in lines[1].split()[:num_a+1]]
b_list = [int(v) for v in lines[2].split()[:num_b+1]]

res1 = [
    a_list[a_i-1]+b_list[b_i-1]-discount for a_i, b_i, discount in [
        map(int, l.split())  for l in lines[3:num_m+3]
    ]
]

res2 = min(a_list) + min (b_list)

print(min(min(res1), res2))
Buggy python submission (verdict: Runtime Error):
lines = sys.stdin.readlines()

digits = int(lines[0][0])

nums = [l.split() for l in lines[1:]]
result = ['0'] * digits

digit_set = set()
for num in nums:
    num_index = int(num[0])-1
    num_value = num[1]
    if num_index in digit_set and result[num_index] != num_value:
        print(-1)
        break
    digit_set.add(num_index)
    result[num_index] = num_value
else:
    if digits > 1 and result[0] == '0':
        print(-1)
    else:
        print(''.join(result))
        

Fixed submission:
n = int(input())
print(n // 2  + (n % 2))

Buggy python submission (verdict: Runtime Error):
n = input()
print(n // 2  + (n % 2))

Fixed submission:
n = int(input())
print(n // 2  + (n % 2))

Buggy python submission (verdict: Runtime Error):
n = input()
res = n // 2 
print(res + (res & 2))

Fixed submission:
n = int(input())
print(n // 2  + (n % 2))
Buggy python submission (verdict: Runtime Error):
import sys
import numpy as np

lines = sys.stdin.readlines()
bingo_card = np.zeros([3,3])
for i, l in enumerate(input()):
    if i <= 2:
        bingo_card[i] = [int(num) for num in l.split()]
    else:
        bingo_card[bingo_card == int(l)] = None
        
check_arr = np.isnan(bingo_card)
if check_arr[0].sum() == 3 or check_arr[1].sum() == 3 or check_arr[2].sum() == 3:
    print('Yes')
elif check_arr[:, 0].sum() == 3 or check_arr[:, 1].sum() == 3 or check_arr[:, 2].sum() == 3:
    print('Yes')
elif check_arr[0,0] and check_arr[1,1] and check_arr[2,2]:
    print('Yes')
elif check_arr[0,2] and check_arr[1,1] and check_arr[2,0]:
    print('Yes')
else:
    print('No')

Fixed submission:
import sys
import numpy as np

lines = sys.stdin.readlines()
bingo_card = np.zeros([3,3])
for i, l in enumerate(lines):
    if i <= 2:
        bingo_card[i] = [int(num) for num in l.split()]
    else:
        bingo_card[bingo_card == int(l)] = None
        
check_arr = np.isnan(bingo_card)
if check_arr[0].sum() == 3 or check_arr[1].sum() == 3 or check_arr[2].sum() == 3:
    print('Yes')
elif check_arr[:, 0].sum() == 3 or check_arr[:, 1].sum() == 3 or check_arr[:, 2].sum() == 3:
    print('Yes')
elif check_arr[0,0] and check_arr[1,1] and check_arr[2,2]:
    print('Yes')
elif check_arr[0,2] and check_arr[1,1] and check_arr[2,0]:
    print('Yes')
else:
    print('No')
Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
import numpy as np

n, k = map(int, input().split())
a = np.zeros(n)

for i in range(k):
    d = input()
    temp = input()

    for j in range(int(d)):
        a[int(temp[j*2]) - 1] = 1

count = 0
for i in range(n):
    if a[i] == 0:
        count = count + 1

print(count)


Fixed submission:
# -*- coding: utf-8 -*-
import numpy as np

n, k = map(int, input().split())
a = np.zeros(n)

for i in range(k):
    d = input()
    temp = input()

    for j in range(int(d)):
        a[int(temp.split(' ')[j]) - 1] = 1

count = 0
for i in range(n):
    if a[i] == 0:
        count = count + 1

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


if -(-c // b) <= -(-a // d):
    print('Yes')
else:
    print('No')


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

if s <= w:
    print('unsafe')
else:
    print('safe')

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

if s =< w:
    print('unsafe')
elif s > w:
    print('safe')
    

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

if s <= w:
    print('unsafe')
else:
    print('safe')

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

if s > w:
    print('safe')
elif s =< w:
    print('unsafe')

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

if s <= w:
    print('unsafe')
else:
    print('safe')
Buggy python submission (verdict: Runtime Error):
a, b, c, d = map(int,input().split())


if (-(-c // b)) <= (-(-a // d):
    print('Yes')
else:
    print('No')


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

tk_count = -(-c // b)
ao_count = -(-a // d)

if tk_count <= ao_count:
    print('Yes')
else:
    print('No')

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


if (-(-c // b)) >= (-(-a // d):
    print('Yes')
else:
    print('No')


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

tk_count = -(-c // b)
ao_count = -(-a // d)

if tk_count <= ao_count:
    print('Yes')
else:
    print('No')
Buggy python submission (verdict: Runtime Error):
n = int(input())
a = [input().split() for i in range(n)]

c = collections.counter(a)

print(len(c))


Fixed submission:
import collections
n = int(input())
a = [input() for i in range(n)]
list_a = list(a)
c = collections.Counter(a)

print(len(c))

Buggy python submission (verdict: Runtime Error):
n = int(input())
a = [input() for i in range(n)]

c = collections.counter(a)

print(len(c))

Fixed submission:
import collections
n = int(input())
a = [input() for i in range(n)]
list_a = list(a)
c = collections.Counter(a)

print(len(c))
Buggy python submission (verdict: Runtime Error):
R = float(input())
L = 2*math.pi*R
print(L)

Fixed submission:
R = int(input())
L = 2 * 3.14159265358979 * R
print(L)
Buggy python submission (verdict: Runtime Error):
N = int(input())
if '7' in N:
    print('Yes')
else:
    print('No')

Fixed submission:
n = input()
ans = 'No'
for i in n:
    if i == '7':
        ans = 'Yes'
print(ans)
Buggy python submission (verdict: Runtime Error):
H,N = map(int,input().split())
A = list(map(int,input().split()))
new_A = sorted(A,reverse=True)

ans = 'yes'

for i in range(N + 1):
    if new_A[1] + new_A[2] < H:
        ans = 'No'
    if N < 2:
        ans = 'No'

print(ans)


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


ans = 'Yes'


if sum(A) < H:
    ans = 'No'


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

if sum(a,b,c) >= 22:
    print('bust')
else:
    print('win')

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

if a + b + c >= 22:
    print('bust')
else:
    print('win')
Buggy python submission (verdict: Runtime Error):
S = input()

count=0

for i in range(len(S) // 2):
    if S[i] != RS[-1-i]:
        count += 1

print(count)


Fixed submission:
S = input()


count=0

for i in range(len(S) // 2):
    if S[i] != S[-1-i]:
        count += 1

print(count)

Buggy python submission (verdict: Runtime Error):
S = input()

count=0

for i in range(len(S) // 2):
    if S[i] != RS[-i-1]:
        count += 1

print(count)

Fixed submission:
S = input()


count=0

for i in range(len(S) // 2):
    if S[i] != S[-1-i]:
        count += 1

print(count)

Buggy python submission (verdict: Runtime Error):
S = input()
RS = reversed(S)

count=0

for i in range(len(S) // 2):
    if S[i] != RS[i]:
        count += 1

print(count)
        


Fixed submission:
S = input()


count=0

for i in range(len(S) // 2):
    if S[i] != S[-1-i]:
        count += 1

print(count)
Buggy python submission (verdict: Runtime Error):
n = int(input())
s = input()

ans = 'Yes'

for i in ((n // 2) - 1):
    if s[i] != s[i + (n // 2)]:
        ans = 'No'

print(ans)
        
        


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

ans = 'Yes'

if n % 2 != 0:
    ans = 'No'
    
for i in range(n // 2):
    if s[i] != s[i + (n // 2)]:
        ans = 'No'

print(ans)

Buggy python submission (verdict: Runtime Error):
n = int(input())
s = input()

ans = 'Yes'

for i in (n // 2):
    if s[i] != s[i + (n // 2)]:
        ans = 'No'

print(ans)
        
        


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

ans = 'Yes'

if n % 2 != 0:
    ans = 'No'
    
for i in range(n // 2):
    if s[i] != s[i + (n // 2)]:
        ans = 'No'

print(ans)
Buggy python submission (verdict: Runtime Error):
D = input()

today = "Christmas"

x = 25 - D

today += x * " Eve"

print(today)
    



Fixed submission:
D = int(input())
#かわむら

today = "Christmas"

x = 25 - D

today += x * " Eve"

print(today)
Buggy python submission (verdict: Runtime Error):
ab=raw_input().split()
a=int(ab[0])
b=int(ab[1])
num=1
if a <=0 and b>=0:
    print 'Zero'
else:
    for val in range(a,b+1,1):
        num*=val
    if num > 0:
        print 'Positive'
    elif num==0:
        print 'Zero'
    else :
        print'Negative'

Fixed submission:
ab=raw_input().split()
a=int(ab[0])
b=int(ab[1])
num=1
if a <=0 and b>=0:
    print 'Zero'
elif a>0:
    print 'Positive'
elif (b-a)%2==0:
    print 'Negative'
else:
    print'Positive'

Buggy python submission (verdict: Runtime Error):
ab=raw_input().split()
a=int(ab[0])
b=int(ab[1])
num=1
for val in range(a,b+1,1):
    num*=val

if num > 0:
    print 'Positive'
elif num==0:
    print 'Zero'
else :
    print'Negative'

Fixed submission:
ab=raw_input().split()
a=int(ab[0])
b=int(ab[1])
num=1
if a <=0 and b>=0:
    print 'Zero'
elif a>0:
    print 'Positive'
elif (b-a)%2==0:
    print 'Negative'
else:
    print'Positive'
Buggy python submission (verdict: Time Limit Exceeded):
import math
k = int(input())
s = 0
for p in range(1,k+1):
	for q in range(1,k+1):
			for r in range(1,k+1):
				if r == 1:
					s += 1
				else:
					s = s + math.gcd(p,math.gcd(q,r))
print(s)

Fixed submission:
import math
k = int(input())
s = 0
for p in range(1,k+1):
	for q in range(1,k+1):
		temp = math.gcd(p,q)
		for r in range(1,k+1):
			if r == 1:
				s += 1
			else:
				s = s + math.gcd(temp,r)
print(s)
Buggy python submission (verdict: Runtime Error):

# input
X = int( input() )
maxA = 1000
pow5 = list()
for aa in range(maxA):
    pow5.append( aa**5 )
    
# calc    
ans = False
a = 0
b = 0
for ii in range(maxA):  
    if( ans==False ):
        X1 = X - pow5[ii]
        X2 = X + pow5[ii]
        if( X1 in pow5 ):
            b = - ii
            a = pow5.index( X1 )
            ans = True
        
    if( ans==False ):
        if( X2 in pow5 ):
            b = ii
            a = pow5.index( X1 )
            ans = True

# out
print( str(a)+' '+str(b) )

Fixed submission:
# input
X = int( input() )
maxA = 1000
pow5 = list()
for aa in range(maxA):
    pow5.append( aa**5 )
    
# calc    
ans = False
for ii in range(maxA):  
    if( ans==False ):
        X1 = X - pow5[ii]
        X2 = X + pow5[ii]
        if( X1 in pow5 ):
            b = - ii
            a = pow5.index( X1 )
            ans = True
        
    if( ans==False ):
        if( X2 in pow5 ):
            b = ii
            a = pow5.index( X2 )
            ans = True

# out
if(ans):
    print( str(a)+' '+str(b) )

Buggy python submission (verdict: Runtime Error):
# input
X = int( input() )
maxA = 70
pow5 = list()
for aa in range(maxA):
    pow5.append( aa**5 )
    
# calc    
ans = False
a = 0
b = 0
for ii in range(maxA):  
    if( ans==False ):
        X1 = X - pow5[ii]
        X2 = X + pow5[ii]
        if( X1 in pow5 ):
            b = - ii
            a = pow5.index( X1 )
            ans = True
        
    if( ans==False ):
        if( X2 in pow5 ):
            b = ii
            a = pow5.index( X1 )
            ans = True

# out
print( str(a)+' '+str(b) )

Fixed submission:
# input
X = int( input() )
maxA = 1000
pow5 = list()
for aa in range(maxA):
    pow5.append( aa**5 )
    
# calc    
ans = False
for ii in range(maxA):  
    if( ans==False ):
        X1 = X - pow5[ii]
        X2 = X + pow5[ii]
        if( X1 in pow5 ):
            b = - ii
            a = pow5.index( X1 )
            ans = True
        
    if( ans==False ):
        if( X2 in pow5 ):
            b = ii
            a = pow5.index( X2 )
            ans = True

# out
if(ans):
    print( str(a)+' '+str(b) )
Buggy python submission (verdict: Runtime Error):
S = str( input() )
T = str( input() )
A = int( input() )
B = int( input() )
U = str( input() )

if( S==U ):
    A-=1
if( T==U ):
    B-=1

print( str(A)+" "+str(B) )

Fixed submission:
S, T = input().split()
A, B = map( int, input().split() )
U    = input()

if( S==U ):
    A-=1
if( T==U ):
    B-=1

print( str(A)+" "+str(B) )
Buggy python submission (verdict: Runtime Error):
def find_max_expectation( P, K ):
    # P is a np.array( N, )
    # K is a int
    
    if( len(P)==0 ):
        return np.nan
    
    st_idx  = 0
    max_sum = 0
    for nn in range( K ):
        max_sum += P[nn]
    
    tmp = max_sum
    for nn in range( K, len(P) ):
        tmp -= P[nn-K]
        tmp += P[nn]
        if( tmp > max_sum ):
            st_idx = nn-K+1
        
    ans = 0
    for nn in range( st_idx, st_idx+K ):
        tmp = 1 + 0.5*( P[nn]-1 )
        ans += tmp
    
    return ans


# input
N, K = map( int, input().split() )
P    = np.array( [int(x) for x in input().split()] )

print( find_max_expectation( P, K ) )

Fixed submission:
# input
N, K = map( int, input().split() )
P    = [int(x) for x in input().split()]

# calc cumsum
C    = list()
cumsum = 0
for ii in range( len(P) ):
    E = (1+P[ii])/2
    C.append( cumsum + E )
    cumsum += E

ans = 0.0
if( N==K ):
    ans = C[-1]
for ii in range( K, N ):
    E = C[ii] - C[ii-K]
    if( ans < E ):
        ans = E

# output        
print( ans )
Buggy python submission (verdict: Runtime Error):

A, B, C = list(input() for i in range(3))

turn = "a"

while True:
    if turn == 'a':
        if len(A) != 0:
            turn = A.pop(0)
        else:
            print('A')
            break
    elif turn == 'b':
        if len(B) != 0:
            turn = B.pop(0)
        else:
            print('B')
            break
    elif turn == 'c':
        if len(C) != 0:
            turn = C.pop(0)
        else:
            print('C')
            break

Fixed submission:
A, B, C = [list(input()) for i in range(3)]


turn = "a"

while True:
    if turn == 'a':
        if len(A) != 0:
            turn = A.pop(0)
        else:
            print('A')
            break
    elif turn == 'b':
        if len(B) != 0:
            turn = B.pop(0)
        else:
            print('B')
            break
    elif turn == 'c':
        if len(C) != 0:
            turn = C.pop(0)
        else:
            print('C')
            break
Buggy python submission (verdict: Runtime Error):
a, b = map(int, input().split)
if (a * b) % 2 != 0:
  print('Odd')
else:
  print('Even')

Fixed submission:
a, b = map(int, input().split())
if (a * b) % 2 != 0:
  print('Odd')
else:
  print('Even')
Buggy python submission (verdict: Runtime Error):
x, y = map(int,input().split())
if x<y:
  print("unsafe")
else:
  print("safe')

Fixed submission:
s, w = map(int,input().split())
if w>=s:
  print("unsafe")
else:
  print("safe")

Buggy python submission (verdict: Runtime Error):
S=input()
count=0
#S3=''

#for i in range(len(S)):
#    S3+=str(int(S[i])%3)
for i in range(0,len(S)-4):
    check3=int(S[i])+int(S[i+1])+int(S[i+2])+int(S[i+3])
    for j in range(i+5,len(S)+1):
        check3+=int(S[j-1])
        check3%=3
        if check3==0:
            if int(S[i:j])%673==0:
                count+=1
                
print(str(count))

Fixed submission:
S,W=map(int,input().split()) 
if S<=W:
    print('unsafe')
else:
    print('safe')

Buggy python submission (verdict: Runtime Error):
S=input()
count=0

for i in range(0,len(S)-4):
    check3=int(S[i])+int(S[i+1])+int(S[i+2])+int(S[i+3])
    for j in range(i+5,len(S)+1):
        check3+=int(S[j-1])
        check3%=3
        if check3==0:
            if int(S[i:j])%673==0:
                count+=1
                
print(str(count))

Fixed submission:
S,W=map(int,input().split()) 
if S<=W:
    print('unsafe')
else:
    print('safe')

Buggy python submission (verdict: Runtime Error):
S=input()
count=0
#S3=''

#for i in range(len(S)):
#    S3+=str(int(S[i])%3)
for i in range(0,len(S)-4):
    check3=int(S[i])+int(S[i+1])+int(S[i+2])+int(S[i+3])
    for j in range(i+5,len(S)+1):
        check3+=int(S[j-1])
        check3%=3
        if check3==0:
            if int(S[i:j])%673==0:
                count+=1
                
print(str(count))

Fixed submission:
S,W=map(int,input().split()) 
if S<=W:
    print('unsafe')
else:
    print('safe')

Buggy python submission (verdict: Runtime Error):
S=[str(input()) for i in range(2*10^1-1)]
S.pop(0)
print(len(set(S)))

Fixed submission:
S,W=map(int,input().split()) 
if S<=W:
    print('unsafe')
else:
    print('safe')
Buggy python submission (verdict: Runtime Error):
N=input()
S = [str(input()) for i in range(N)]
print(len(set(S)))

Fixed submission:
N=int(input())
S = [str(input()) for i in range(N)]
print(len(set(S)))

Buggy python submission (verdict: Runtime Error):
S = [str(input()) for i in range(2*10^5)]
#(2*10^5):    
S.pop(0)
if '' in S:
    print(len(set(S))-1)
else:
    print(len(set(S)))

Fixed submission:
N=int(input())
S = [str(input()) for i in range(N)]
print(len(set(S)))

Buggy python submission (verdict: Runtime Error):
S=[str(input()) for i in range(2*10^5-1)]
S.pop(0)
print(len(set(S)))

Fixed submission:
N=int(input())
S = [str(input()) for i in range(N)]
print(len(set(S)))

Buggy python submission (verdict: Runtime Error):
S=[str(input()) for i in range(2*10^1-1)]
S.pop(0)
print(len(set(S))

Fixed submission:
N=int(input())
S = [str(input()) for i in range(N)]
print(len(set(S)))
Buggy python submission (verdict: Runtime Error):
N=input()
S=input()
R=[]
G=[]
B=[]
for i in range(len(S)):
    if S[i]=='R':
        R.append(i)
    if S[i]=='G':
        G.append(i)
    if S[i]=='B':
        B.append(i)

count=0
for i in range(len(R)):
    for j in range(len(G)):

        if max(R[i],G[j])+abs(R[i]-G[j]) in B:
            count+=1

        if min(R[i],G[j])-abs(R[i]-G[j]) in B:
            count+=1

        if (R[i]+G[j])/2 in B:
            count+=1


print(str((len(R)*len(G)*len(B))-count))


Fixed submission:
N=input()
if "7" in N:
  print('Yes')
else:
  print('No')

Buggy python submission (verdict: Runtime Error):
N=input()
S=input()
Sn=[]
R=0
G=0
B=0
for i in range(len(S)):
    if S[i]=='R':
        R+=1
        Sn.append(1)
    elif S[i]=='G':
        G+=1
        Sn.append(2)
    else:
        B+=1
        Sn.append(3)

count=0
for start in range(len(S)):
        for diff in range(1,int((len(S)-start+1)/2)):
            if (Sn[start]-Sn[start+diff])*(Sn[start+diff]-Sn[start+(2*diff)])*(Sn[start]-Sn[start+(2*diff)])!=0: 
                count+=1
                
print(str((R*G*B)-count))

Fixed submission:
N=input()
if "7" in N:
  print('Yes')
else:
  print('No')

Buggy python submission (verdict: Runtime Error):
N=input()
S=input()
Sn=[]
R=0
G=0
B=0
for i in range(len(S)):
    if S[i]=='R':
        R+=1
        Sn.append(1)
    elif S[i]=='G':
        G+=1
        Sn.append(2)
    else:
        B+=1
        Sn.append(3)

count=0
for start in range(len(S)):
        for diff in range(1,int((len(S)-start+1)/2)):
      
            if (Sn[start]-Sn[start+diff])*(Sn[start+diff]-Sn[start+(2*diff)])*(Sn[start]-Sn[start+(2*diff)])!=0: 
                count+=1
                
print(str((R*G*B)-count))

Fixed submission:
N=input()
if "7" in N:
  print('Yes')
else:
  print('No')