Harryxun/testdata huggingface dataset:
Buggy python submission (verdict: Runtime Error):
if a*b%2 == 0:
  print("Even")
else:
  print("Odd")


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

if a*b%2 == 0:
    print("Even")
else:
    print("Odd")

Buggy python submission (verdict: Runtime Error):
a = int(input())
b = int(input())

if a*b%2 == 0:
  print("Even")
else:
  print("Odd")


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

if a*b%2 == 0:
    print("Even")
else:
    print("Odd")

Buggy python submission (verdict: Runtime Error):
a = int(input())
b = int(input())

if a*b%2 == 0:
    print("Even")
else:
    print("Odd")

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

if a*b%2 == 0:
    print("Even")
else:
    print("Odd")

Buggy python submission (verdict: Runtime Error):
a = int(input())
b = int(input())

if a%2==0 or b%2==0:
    print("Even")
else:
    print("Odd")

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

if a*b%2 == 0:
    print("Even")
else:
    print("Odd")
Buggy python submission (verdict: Runtime Error):
a,b,c=input().split()
s=700
if a=='o' :
  s=s+100
if b=='o' :
  s=s+100
if c=='o' :
  s=s+100
print(s)

Fixed submission:
a,b,c=input()
s=700
if a=='o' :
  s=s+100
if b=='o' :
  s=s+100
if c=='o' :
  s=s+100
print(s)
Buggy python submission (verdict: Runtime Error):
r=int(input())
g=int(input())
b=int(input())
num=100*r+10*g+b
if num%4==0:
    print("YES")
else:
    print("NO")
return 0

Fixed submission:
r,g,b=(int(x) for x in input().split())

num=100*r+10*g+b
if num%4==0:
    print("YES")
else:
    print("NO")

Buggy python submission (verdict: Runtime Error):
r=int(input())
g=int(input())
b=int(input())
num=100*r+10*g+b
if num%4==0:
    print("YES")
else:
    print("NO")

Fixed submission:
r,g,b=(int(x) for x in input().split())

num=100*r+10*g+b
if num%4==0:
    print("YES")
else:
    print("NO")

Buggy python submission (verdict: Runtime Error):
r=int(input())
g=int(input())
b=int(input())
a=100*r+10*g+b

if a%4 ==0:
    print("YES")
else:
    primt("NO")

Fixed submission:
r,g,b=(int(x) for x in input().split())

num=100*r+10*g+b
if num%4==0:
    print("YES")
else:
    print("NO")

Buggy python submission (verdict: Runtime Error):
r,g,b=input()
if (100*r+10*g+b)/4==0:
	print("YES")
else:
  print("NO")

Fixed submission:
r,g,b=(int(x) for x in input().split())

num=100*r+10*g+b
if num%4==0:
    print("YES")
else:
    print("NO")
Buggy python submission (verdict: Runtime Error):
s = input().rstrip()

s1 = "2018" + s[4:] if s.startwith("2017") else s


Fixed submission:
s = input().rstrip()

s1 = "2018" + s[4:] if s.startswith("2017") else s
print(s1)
Buggy python submission (verdict: Runtime Error):
a=int(input())
b=int(input())
x=int(input())

if (a > x):
	print("No")
elif(a+b)>x:
	print("Yes")
else:
	print("No")

Fixed submission:
a=input().strip().split()
b=[int(i) for i in a]

if (b[0] > b[2]):
	print("NO")
elif(b[0]+b[1])>b[2]:
	print("YES")
else:
	print("NO")
Buggy python submission (verdict: Runtime Error):
import math
n = input()
a = list(map(int,input().split()))
ans = float("inf")
for i in a:
  ans = min(ans, len(bin(i)) - bin(i).rfind("1") - 1)
print(round(ans)

Fixed submission:
import math
n = input()
a = list(map(int, input().split()))
ans = float("inf")
for i in a:
    ans = min(ans, len(bin(i)) - bin(i).rfind("1") - 1)
print(round(ans))

Buggy python submission (verdict: Runtime Error):
import math
n = input()
a = list(map(int,input().split()))
ans = float("inf")
for i in a:
  ans = min(ans, len(bin(i)) - bin(i).rfing("1") - 1)
print(round(ans)

Fixed submission:
import math
n = input()
a = list(map(int, input().split()))
ans = float("inf")
for i in a:
    ans = min(ans, len(bin(i)) - bin(i).rfind("1") - 1)
print(round(ans))
Buggy python submission (verdict: Runtime Error):
N = int(input())
cards = list(map(int, input().split()))
l.sort(reverse=True)
print(sum(cards[0::2]) - sum(cards[1::2]))

Fixed submission:
N = int(input())
cards = list(map(int, input().split()))
cards.sort(reverse=True)
print(sum(cards[0::2]) - sum(cards[1::2]))
Buggy python submission (verdict: Runtime Error):
s = input()
print(s[0] + len(s[1:-1]) + s[-1])

Fixed submission:
s = input()
print(s[0] + str(len(s[1:-1])) + s[-1])
Buggy python submission (verdict: Time Limit Exceeded):
s = input()

maxlen = 0
for i, char_1 in enumerate(s):
  for j, char_2 in enumerate(s):
    if char_1=='A' and char_2=='Z' and maxlen < j - i + 1:
      maxlen = j - i + 1
print(maxlen)

Fixed submission:
s = input()
print(s.rfind('Z') - s.find('A') + 1)
Buggy python submission (verdict: Runtime Error):
pay = input('')
yen1 = input('')
amari = pay % 500
if yen1 >= amari:
  print('YES')
else:
  print('NO')
  

Fixed submission:
pay = int(input(''))
yen1 = int(input(''))
amari = pay % 500
if yen1 >= amari:
  print('Yes')
else:
  print('No')
Buggy python submission (verdict: Runtime Error):
N, A, B = list(map(int, input('').split()))
answer = 0
for x in range(1, N + 1):
  total = sum(map(int, list(str(x)))
  if A <= total <= B:
    answer += x

print(answer)


Fixed submission:
N, A, B = list(map(int, input('').split()))
total = 0
for x in range(1, N + 1):
  num = str(x)
  digit_total = 0
  for y in range(len(num)):
    digit_total += int(num[y])
  if digit_total >= A and digit_total <= B:
    total += x

print(total)
Buggy python submission (verdict: Runtime Error):
digits = input('')
digits = digits.split(' ')
average = math.round(int(digits[0]) + int(digits[1]) / 2)
print(average)

Fixed submission:
import math

digits = input('')
digits = digits.split(' ')
average = math.ceil((int(digits[0]) + int(digits[1])) / 2)
print(average)
Buggy python submission (verdict: Runtime Error):
first = sorted(list(input('')))
second = sorted(list(input('')), reverse=True)
length = len(first) < len(second)

result = False
check_equal = False
for (f, s) in zip(first, second):
  check_equal = (s == f)
  if !check_equal:
    result = (f < s)
    break

if (length and check_equal) or result:
  print('Yes')
else:
  print('No')


Fixed submission:
first = sorted(list(input('')))
second = sorted(list(input('')), reverse=True)
length = len(first) < len(second)

result = False
check_equal = False
for (f, s) in zip(first, second):
  check_equal = (s == f)
  if f < s:
    result = True
    break
  elif f > s:
    result = False
    break

if (length and check_equal) or result:
  print('Yes')
else:
  print('No')
Buggy python submission (verdict: Runtime Error):
digits = input('')
count = 0
if digits[0] == 1:
  count++
if digits[1] == 1:
  count++
if digits[2] == 1:
  count++
print count

Fixed submission:
digits = list(input(''))
count = 0
if digits[0] == '1':
  count += 1
if digits[1] == '1':
  count += 1
if digits[2] == '1':
  count += 1
print(count)
Buggy python submission (verdict: Runtime Error):
str = input('')
start = str[:1]
end = str[-1:]
print(start + (len(str) - 2) + end)

Fixed submission:
input_str = input('')
start = input_str[:1]
end = input_str[-1:]
print(start + str((len(input_str) - 2)) + end)
Buggy python submission (verdict: Runtime Error):
digits = input('')
if int(digits) % 4:
  print 'YES'
else:
  print 'NO'


Fixed submission:
digits = input('')
digits = digits.split(' ')
if int(''.join(digits)) % 4 == 0:
  print('YES')
else:
  print('NO')
Buggy python submission (verdict: Runtime Error):
def check(x, y, S):

K, S = list(map(int, input('').split()))
count = 0
for x in range(K+1):
  for y in range(K+1):
    if x + y <= S:
      count += 1
print(count)


Fixed submission:
K, S = list(map(int, input('').split()))
count = 0
for x in range(K+1):
  for y in range(K+1):
    if x + y <= S and x + y + K >= S:
      count += 1
print(count)

Buggy python submission (verdict: Runtime Error):
def check(x, y, S):

K, S = list(map(int, input('').split()))
count = 0
for x in range(K+1):
  for y in range(K+1):
    if x + y <= S:
      count += 1
print(count)

Fixed submission:
K, S = list(map(int, input('').split()))
count = 0
for x in range(K+1):
  for y in range(K+1):
    if x + y <= S and x + y + K >= S:
      count += 1
print(count)

Buggy python submission (verdict: Time Limit Exceeded):
def check(x, y, K, S):
  if x + y > S:
    return False
  for z in range(K+1):
    if x + y + z == S:
      return True
  return False

K, S = list(map(int, input('').split()))
count = 0
for x in range(K+1):
  for y in range(K+1):
    if check(x, y, K, S):
      count += 1
print(count)

Fixed submission:
K, S = list(map(int, input('').split()))
count = 0
for x in range(K+1):
  for y in range(K+1):
    if x + y <= S and x + y + K >= S:
      count += 1
print(count)

Buggy python submission (verdict: Time Limit Exceeded):
def check(x, y, K, S):
  for z in range(K+1):
    if x + y + z == S:
      return True
  return False

K, S = list(map(int, input('').split()))
count = 0
for x in range(K+1):
  for y in range(K+1):
    if check(x, y, K, S):
      count += 1
print(count)

Fixed submission:
K, S = list(map(int, input('').split()))
count = 0
for x in range(K+1):
  for y in range(K+1):
    if x + y <= S and x + y + K >= S:
      count += 1
print(count)

Buggy python submission (verdict: Runtime Error):
def check(x, y, K, S):
  for z in range(K+1):
    if x + y + z == S:
      return true
  return false

K, S = list(map(int, input('').split()))
count = 0
for x in range(K+1):
  for y in range(K+1):
    if check(x, y, K, S):
      count += 1
print(count)

Fixed submission:
K, S = list(map(int, input('').split()))
count = 0
for x in range(K+1):
  for y in range(K+1):
    if x + y <= S and x + y + K >= S:
      count += 1
print(count)

Buggy python submission (verdict: Time Limit Exceeded):
K, S = list(map(int, input('').split()))
count = 0
for x in range(K+1):
  for y in range(K+1):
    for z in range(K+1):
      if x + y + z == S:
      	count += 1
print(count)

Fixed submission:
K, S = list(map(int, input('').split()))
count = 0
for x in range(K+1):
  for y in range(K+1):
    if x + y <= S and x + y + K >= S:
      count += 1
print(count)

Buggy python submission (verdict: Time Limit Exceeded):
K, S = list(map(int, input('').split()))
count = 0
for x in range(K+1):
  for y in range(K+1):
    for z in range(K+1):
      if x + y + z == S:
      	count += 1
print(count)

Fixed submission:
K, S = list(map(int, input('').split()))
count = 0
for x in range(K+1):
  for y in range(K+1):
    if x + y <= S and x + y + K >= S:
      count += 1
print(count)
Buggy python submission (verdict: Runtime Error):
a=int(input())
print(700+a.count("o")*100)

Fixed submission:
a=input()
print(700+a.count("o")*100)
Buggy python submission (verdict: Runtime Error):
A,B,X = map(int, input().sp;it())
 
if (X>=A and X<=(A+B)):
    print("YES")
else:
    print("NO")

Fixed submission:
A,B,X = (int(i) for i in input().split())
 
if (X>=A and X<=(A+B)):
    print("YES")
else:
    print("NO")

Buggy python submission (verdict: Runtime Error):
a,b,c=map(int, input.split())
print("YES" if a<=c<=a+b else "NO")

Fixed submission:
A,B,X = (int(i) for i in input().split())
 
if (X>=A and X<=(A+B)):
    print("YES")
else:
    print("NO")
Buggy python submission (verdict: Runtime Error):
x=input()
x.solt()
if x=="abc":
	print("YES")
else:
	print("NO")


Fixed submission:
print("Yes" if len(set(input())) == 3 else "No")

Buggy python submission (verdict: Runtime Error):
x=input()
x.solt()
if x==abc:
	print("YES")
else:
	print("NO")


Fixed submission:
print("Yes" if len(set(input())) == 3 else "No")
Buggy python submission (verdict: Runtime Error):
a=[]
for _ in range(4):
	a.append(int(input())

print(min(a[0],a[1])+min(a[2],a[3]))

Fixed submission:
a=[]
for _ in range(4):
	a.append(int(input()))

print(min(a[0],a[1])+min(a[2],a[3]))

Buggy python submission (verdict: Runtime Error):
N=int.input()
a=[int.input() for i in range(2)]
M=int.input()
b=[int.input() for i in range(2)]
print(min(a)+min(b))

Fixed submission:
a=[]
for _ in range(4):
	a.append(int(input()))

print(min(a[0],a[1])+min(a[2],a[3]))
Buggy python submission (verdict: Runtime Error):
a,b,c=map(int,input().split())
print("YES" if a[0)+a[1]>=a[3] else "NO")

Fixed submission:
a,b,c=map(int,input().split())
print("Yes" if a+b>=c else "No")

Buggy python submission (verdict: Runtime Error):
a=map(int,input().split())
print("YES" if a[0)+a[1]>=a[3] else "NO")

Fixed submission:
a,b,c=map(int,input().split())
print("Yes" if a+b>=c else "No")

Buggy python submission (verdict: Runtime Error):
a=map(int, input().split)
print("YES" if a[0)+a[1]>=a[3] else "NO")

Fixed submission:
a,b,c=map(int,input().split())
print("Yes" if a+b>=c else "No")
Buggy python submission (verdict: Runtime Error):
N, X = input().strip().split()
N = int(N)
X = int(X)
donuts = sorted(int(input()) for i in range(N-1))
partial_sum = [sum(donuts[:i]) for i in range(N-1)]
if partial_sum[-1] > X:
    print(N-1 + (X-partial_sum[-1]) // donuts[0])
else:
    print(sum(1 for x in partial_sum if x <= X))

Fixed submission:
S = list(input())
S = [100 for s in S if s == 'o']
print(700+sum(S))
Buggy python submission (verdict: Runtime Error):
N = int(input())
A = list(sorted(map(int, input().split())))
B = list(sorted(map(int, input().split()))
C = list(sorted(map(int, input().split())))
 
import bisect
upper_condition = [bisect.bisect_left(A, b) for b in B]
lower_condition = [N - bisect.bisect_right(C, b) for b in B]
 
print(sum(map(lambda x: x[0]*x[1], zip(upper_condition, lower_condition))))

Fixed submission:
N = int(input().rstrip())
A = sorted(list(map(int, input().rstrip().split())))
B = sorted(list(map(int, input().rstrip().split())))
C = sorted(list(map(int, input().rstrip().split())))

import bisect
upper_condition = [bisect.bisect_left(A, b) for b in B]
lower_condition = [N - bisect.bisect_right(C, b) for b in B]

print(sum(map(lambda x: x[0]*x[1], zip(upper_condition, lower_condition))))

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

import bisect
upper_condtion = [bisect.bisect_left(A, b) for b in B]
lower_condition = [N - bisect.bisect_right(C, b) for b in B]

print(sum(map(lambda x: x[0]*x[1], zip(upper_condition, lower_condition))))

Fixed submission:
N = int(input().rstrip())
A = sorted(list(map(int, input().rstrip().split())))
B = sorted(list(map(int, input().rstrip().split())))
C = sorted(list(map(int, input().rstrip().split())))

import bisect
upper_condition = [bisect.bisect_left(A, b) for b in B]
lower_condition = [N - bisect.bisect_right(C, b) for b in B]

print(sum(map(lambda x: x[0]*x[1], zip(upper_condition, lower_condition))))

Buggy python submission (verdict: Runtime Error):
N = int(input())
A = np.array(list(sorted(map(int, input().split()))), dtype=int)
B = np.array(list(sorted(map(int, input().split()))), dtype = int)
C = np.array(list(sorted(map(int, input().split()))), dtype = int)
 
upper_condition = np.array([1 + np.max(np.where(A < b)[0]) for b in B])
lower_condition = np.array([N - np.min(np.where(C > b)[0]) for b in B])
 
print(np.sum(upper_condition*lower_condition))

Fixed submission:
N = int(input().rstrip())
A = sorted(list(map(int, input().rstrip().split())))
B = sorted(list(map(int, input().rstrip().split())))
C = sorted(list(map(int, input().rstrip().split())))

import bisect
upper_condition = [bisect.bisect_left(A, b) for b in B]
lower_condition = [N - bisect.bisect_right(C, b) for b in B]

print(sum(map(lambda x: x[0]*x[1], zip(upper_condition, lower_condition))))
Buggy python submission (verdict: Runtime Error):
if __name__ == '__main__':
    s = raw_input()
    t = list(s).count('〇')
    v = 700 + 100 * t
    print(v)

Fixed submission:
if __name__ == '__main__':
    s = input()
    t = list(s).count('o')
    v = 700 + 100 * t
    print(v)

Buggy python submission (verdict: Runtime Error):
N, X = map(int, input().split())
M = [int(input()) for _ in range(N)]
 
x = X - sum(M)
m = min(M)
print(N + x // m)

Fixed submission:
# -*- coding: utf-8 -*-

option = input()
print (700 + 100 * option.count('o'))

Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
N, X = map(int, input().split())
M = [int(input()) for _ in range(N)]
 
x = X - sum(M)
m = min(M)
 
print (N + x // m)

Fixed submission:
# -*- coding: utf-8 -*-

option = input()
print (700 + 100 * option.count('o'))
Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
N, X = map(int, input().split())
M = [int(input()) for _ in range(N)]
 
x = X - sum(M)
m = Min(M)
 
print (N + x // m)

Fixed submission:
N, X = map(int, input().split())
M = [int(input()) for _ in range(N)]
 
x = X - sum(M)
m = min(M)
print(N + x // m)

Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
N, X = map (int, input().split())
M = [int(input()) for _ in range(N)]

x = X - sum(M)
m = Min(M)

print (N + x // m)

Fixed submission:
N, X = map(int, input().split())
M = [int(input()) for _ in range(N)]
 
x = X - sum(M)
m = min(M)
print(N + x // m)
Buggy python submission (verdict: Runtime Error):
N = int(input())
list = list(map(int,input().split()))
#print(list)
sa_list = []
ai = max(list)
for i in range(N):
    sa2 = abs(( list[i] - ai/2 ) *2)
    
   #print(sa)
    sa_list.append(int(sa2))
#print(sa_list)
basyo = (sa_list.index(min(sa_list)))
ar = list[basyo]
if ai == ar:
    print(str(ai) + " " + str(ai - ar))
else:
    print(str(ai) + " " + str(ar))
    


Fixed submission:
A,B,X = map(int, input().split())
if A + B >= X and A <= X:
    print("YES")
else:
    print("NO")
Buggy python submission (verdict: Runtime Error):
n = list(map(int,input().split()))
if 5 in n :
    n.remove(5)
    if 5 in n and if 7 in n :
        print("YES")
    else:
        print("NO")
else :
    print("NO")

Fixed submission:
n = list(map(int,input().split()))
if 5 in n:
    n.remove(5)
    if 5 in n and 7 in n :
        print("YES")
    else:
        print("NO")
else:
    print("NO")

Buggy python submission (verdict: Runtime Error):
n = list(map(int,input().split()))
if 5 in n :
    n.remove(5)
    elif 5 in n :
        elif 7 in n :
            print("YES")
else :
    print("NO")

Fixed submission:
n = list(map(int,input().split()))
if 5 in n:
    n.remove(5)
    if 5 in n and 7 in n :
        print("YES")
    else:
        print("NO")
else:
    print("NO")

Buggy python submission (verdict: Runtime Error):
n = list(map(int,input().split()))
if 5 in n :
    n.remove(5)
    elif 5 in n :
        elif 7 in n :
                print("YES")
else :
    print("NO")

Fixed submission:
n = list(map(int,input().split()))
if 5 in n:
    n.remove(5)
    if 5 in n and 7 in n :
        print("YES")
    else:
        print("NO")
else:
    print("NO")

Buggy python submission (verdict: Runtime Error):
n = list(map(int,input().split()))
if 5 in n :
    n.remove(5)
    elif 5 in n :
        elif 7 in n :
                print("YES")
else :
    print("NO")

Fixed submission:
n = list(map(int,input().split()))
if 5 in n:
    n.remove(5)
    if 5 in n and 7 in n :
        print("YES")
    else:
        print("NO")
else:
    print("NO")
Buggy python submission (verdict: Runtime Error):
n=int(input())
l=list(map(int,input().split()))
l.sort()
sum=0
for x in range(0,n*2+1,2):
    sum+=min(l[x:x+2])
print(sum)


Fixed submission:
n=int(input())
l=list(map(int,input().split()))
l.sort()
sum=0
for x in range(0,n*2,2):
    sum+=min(l[x:x+2])
print(sum)
Buggy python submission (verdict: Runtime Error):
A, B, X=list(map(int,input().split()))
if B>=X-A&X-A>=0:
 　print("YES")
else:
    print("NO")


Fixed submission:
A, B, X=list(map(int,input().split()))
if B>=X-A&X-A>=0:
     print("YES")
else:
     print("NO")
Buggy python submission (verdict: Time Limit Exceeded):
N = int(input())
list1 = [int(input()) for i in range(N)]

list2 = []
for i in range(N):
    if (list1[i] in list2) == True:
        list2.remove(list1[i])
    else:
        list2.append(list1[i])

print(len(list2))

Fixed submission:
N = int(input())
list1 = [int(input()) for i in range(N)]

dict2 = {}
for i in list1:
    if(i in dict2):
        dict2[i] += 1
    else:
        dict2[i] = 1

count = 0;
for i in dict2.values():
    if i % 2 == 1:
        count += 1
print(count)
Buggy python submission (verdict: Runtime Error):
a=inout().split(' ')
n=int(a[0])
sum=int(a[1])
b=9999999
for i in range(n):
    c=int(input())
    sum-=c
    if b>c:
        b=c
print(sum//b)

Fixed submission:
a=input()
sum=700
for i in a:
    if i=='o':
        sum+=100
print(sum)
Buggy python submission (verdict: Runtime Error):
a=inout().split(' ')
n=int(a[0])
sum=int(a[1])
b=999999
for i in range(n):
    c=int(input())
    if b>c:
        b=c
print(sum//b)

Fixed submission:
a=input().split(' ')
n=int(a[0])
sum=int(a[1])
b=9999999
for i in range(n):
    c=int(input())
    sum-=c
    if b>c:
        b=c
print(n+sum//b)

Buggy python submission (verdict: Runtime Error):
a=inout().split(' ')
n=int(a[0])
sum=int(a[1])
b=9999999
for i in range(n):
    c=int(input())
    sum-=c
    if b>c:
        b=c
print(sum//b)

Fixed submission:
a=input().split(' ')
n=int(a[0])
sum=int(a[1])
b=9999999
for i in range(n):
    c=int(input())
    sum-=c
    if b>c:
        b=c
print(n+sum//b)

Buggy python submission (verdict: Runtime Error):
a=inout().split(' ')
n=int(a[0])
sum=int(a[1])
b=9999999
for i in range(n):
    c=int(input())
    sum-=c
    if b>c:
        b=c
print(sum//b)

Fixed submission:
a=input().split(' ')
n=int(a[0])
sum=int(a[1])
b=9999999
for i in range(n):
    c=int(input())
    sum-=c
    if b>c:
        b=c
print(n+sum//b)