Harryxun/testdata huggingface dataset:
Buggy python submission (verdict: Runtime Error):
def resolve():
    K = int(input())
    temp = 0
    for i in range(1, K + 1, 1):
        for j in range(1, K + 1, 1):
            for k in range(1, K + 1, 1):
                Result = fractions.gcd(i, j)
                temp += fractions.gcd(Result, k)
    print(temp)
resolve()

Fixed submission:
import math
def resolve():
    K = int(input())
    temp = 0
    for i in range(1, K + 1, 1):
        for j in range(1, K + 1, 1):
            for k in range(1, K + 1, 1):
                Result = math.gcd(i, j)
                temp += math.gcd(Result, k)
    print(temp)


resolve()
Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
def resolve():
    a, b, c = map(int, list(input()))
    print(a + b + c)


if __name__ == "__main__":
    resolve()


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

    temp_a = a
    temp_b = b
    a = temp_b
    b = temp_a
    temp_c = c
    temp_a = a
    c = temp_a
    a = temp_c
    print(a, b, c)
resolve()
Buggy python submission (verdict: Time Limit Exceeded):
def resolve():
    a, b = map(int, input().split())
    save_result = []
    append_f = save_result.append
    append_f(a)
    while True:
        a = a - b
        if a < 0:
            abs_s = abs(a)
            append_f(abs_s)
            break
        else:
            append_f(a)

    print(min(save_result))

resolve()

Fixed submission:
def resolve():
    n, k = map(int, input().split())
    print(min(n, n % k, abs(n % k - k)))

resolve()

Buggy python submission (verdict: Time Limit Exceeded):
def resolve():
    a, b = map(int, input().split())
    save_result = []
    save_result.append(a)
    while True:
        a = a - b
        if a < 0:
            abs_s = abs(a)
            save_result.append(abs_s)
            break
        else:
            save_result.append(a)

    print(min(save_result))
resolve()

Fixed submission:
def resolve():
    n, k = map(int, input().split())
    print(min(n, n % k, abs(n % k - k)))

resolve()
Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
text = string(input())
sum = 700
if text[0] == "o":
    sum += 100
if text[1] == "o":
    sum += 100
if text[2] == "o":
    sum += 100
print(sum)

Fixed submission:
# -*- coding: utf-8 -*-
text = input()
sum = 700
if text[0] == "o":
    sum += 100
if text[1] == "o":
    sum += 100
if text[2] == "o":
    sum += 100
print(sum)
Buggy python submission (verdict: Runtime Error):
1000000000000000000k=int(input())
start=100
i=0
while True:
    i+=1
    start*=1.01
    start=int(start)
    if start>k:
        break
print(i)

Fixed submission:
k=int(input())
start=100
i=0
while True:
    i+=1
    start=start*1.01
    if start>k:
        break
    start=int(start)
print(i)
Buggy python submission (verdict: Runtime Error):
r=int(input())
print(2*r*math.pi)

Fixed submission:
import math
import numpy as np
r=int(input())
print(np.round(math.pi*2*r,6))
Buggy python submission (verdict: Runtime Error):
n=int(input())
print(1000*(n/500)+((n%500))

Fixed submission:
n=int(input())
print(1000*(n//500)+5*((n%500)//5))
Buggy python submission (verdict: Runtime Error):
a=[1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
k=int(input())
print(a[k])

Fixed submission:
a=[1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
k=int(input())
print(a[k-1])
Buggy python submission (verdict: Runtime Error):
n = int(input())
num_list = [list(map(int, input().split())) for i in range(n)]

num_list[1].sort(reverse=True)
v = 1 / (4 * num_list[0][1]) * sum(num_list[1])

c = 1

for i in range(num_list[0][1]):
  if num_list[1][i] < v:
    c = 0
    
if c==1:
  print("Yes")
else:
  print("No")

Fixed submission:
a = list(map(int,input().split()))
a[0], a[1] = a[1], a[0]
a[0], a[2] = a[2], a[0]
 
print(a[0], a[1], a[2])

Buggy python submission (verdict: Runtime Error):
a = list(map(int,input().split()))
a[0], a[1] = a[1], a[0]
a[0], a[2] = a[2], a[0]
 
print(a[0]+" "+a[1]+" "+a[2])

Fixed submission:
a = list(map(int,input().split()))
a[0], a[1] = a[1], a[0]
a[0], a[2] = a[2], a[0]
 
print(a[0], a[1], a[2])

Buggy python submission (verdict: Runtime Error):
l = input().split()
 
l[0], l[1] = l[1], 1[0]
l[0], l[2] = l[2], 1[0]
 
print(l[0]+" "+l[1]+" "+l[2])

Fixed submission:
a = list(map(int,input().split()))
a[0], a[1] = a[1], a[0]
a[0], a[2] = a[2], a[0]
 
print(a[0], a[1], a[2])

Buggy python submission (verdict: Runtime Error):
l = input().split()

l[0], l[1] = l[1], 1[0]
l[0], l[2] = l[2], 1[0]

print(l)

Fixed submission:
a = list(map(int,input().split()))
a[0], a[1] = a[1], a[0]
a[0], a[2] = a[2], a[0]
 
print(a[0], a[1], a[2])

Buggy python submission (verdict: Runtime Error):
from sys import stdin

a = stdin.readline().rstrip()
l = list(map(int, a.split()))

l[0], l[1] = l[1], 1[0]
l[0], l[2] = l[2], 1[0]

print(l)

Fixed submission:
a = list(map(int,input().split()))
a[0], a[1] = a[1], a[0]
a[0], a[2] = a[2], a[0]
 
print(a[0], a[1], a[2])
Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
a = list(map(int, input().split()))
answer = []

for x, y in enumerate(a):
  sum = 0
  present = 0
  for s, t in enumerate(a):
    if s != x:
      cost = abs(t-present)
      sum += cost
      present = t
  sum += abs(present-0)
  answer.append(sum)
  print(sum)


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


sum = 0
present = 0
for s, t in enumerate(a):
  sum += abs(t-present)
  present = t
sum += abs(present-0)

for i, each in enumerate(a):
  if i == 0:
    prev = 0
    tmp = each
    next = a[i+1]
  elif i == len(a)-1:
    prev = a[i-1]
    tmp = each
    next = 0
  else:
    prev = a[i-1]
    tmp = each
    next = a[i+1]

  before = abs(prev-tmp) + abs(tmp - next)
  after = abs(prev - next)

  print(sum - before + after)
Buggy python submission (verdict: Runtime Error):
k = int(input())
a, b = map(int, input().split())
judge = 0
for i in range(b-a+1):
    if a+i % k = 0:
        judge = 1
if judge == 1:
    print("OK")
else:
    print("NG")       

Fixed submission:
k = int(input())
a, b = map(int, input().split())
judge = 0
for i in range(b-a+1):
    if (a+i) % k == 0:
        judge = 1
if judge == 1:
    print("OK")
else:
    print("NG")
Buggy python submission (verdict: Runtime Error):
r = int(input())
l = math.pi * 2 * r
print(l)

Fixed submission:
import math
r = int(input())
l = math.pi * 2 * r
print(l)

Buggy python submission (verdict: Runtime Error):
r = int(input())
l = pi * 2 * r
print(l)

Fixed submission:
import math
r = int(input())
l = math.pi * 2 * r
print(l)
Buggy python submission (verdict: Runtime Error):
n=input();
if n // 100 = 7:
    print('Yes')
elif n // 10 = 7:
    print('Yes')
elif n % 10 = 7:
    print('Yes')
else:
    print('No')    

Fixed submission:
n=int(input())
if n // 100 == 7:
    print('Yes')
elif (n // 10) % 10 == 7:
    print('Yes')
elif n % 10 == 7:
    print('Yes')
else:
    print('No')
Buggy python submission (verdict: Runtime Error):
a,b= int(input().split())
if a > 9 or b > 9:
  print(-1)
else:
  print(str(a*b))

Fixed submission:
a,b= map(int,input().split())
if a > 9 or b > 9:
  print(-1)
else:
  print(str(a*b))
Buggy python submission (verdict: Runtime Error):
N = str(input())
Ds = str(input()).split(" ")
answer = 0
 
for di in range(len(Ds)):
  for dii in range(di):
    sum = Ds[di] + Ds[dii] 
    answer += sum
 
print (answer)


Fixed submission:
ABInput = str(input())
 
AB = ABInput.split(" ")
 
A = int(AB[0])
B = int(AB[1])
 
TotalCartain = B * 2
 
if TotalCartain > A or TotalCartain == A:
  print (0)
else:
  print (A-TotalCartain)

Buggy python submission (verdict: Runtime Error):
ABInput = str(input())
 
AB = ABInput.split(" ")
 
A = AB[0]
B = AB[1]
 
TotalCartain = B * 2
 
if TotalCartain > A or TotalCartain == A:
  print (0)
else:
  print (A-TotalCartain)

Fixed submission:
ABInput = str(input())
 
AB = ABInput.split(" ")
 
A = int(AB[0])
B = int(AB[1])
 
TotalCartain = B * 2
 
if TotalCartain > A or TotalCartain == A:
  print (0)
else:
  print (A-TotalCartain)

Buggy python submission (verdict: Runtime Error):
ABInput = str(input())
 
AB = ABInput.split(" ")
 
A = AB[0]
B = AB[1]

TotalCartain = B * 2

if TotalCartain > A or TotalCartain = A:
  print (0)
else:
  print (A-TotalCartain)

Fixed submission:
ABInput = str(input())
 
AB = ABInput.split(" ")
 
A = int(AB[0])
B = int(AB[1])
 
TotalCartain = B * 2
 
if TotalCartain > A or TotalCartain == A:
  print (0)
else:
  print (A-TotalCartain)

Buggy python submission (verdict: Runtime Error):
ABInput = str(input())
 
AB = ABInput.split(" ")
 
A = AB[0]
B = AB[1]
 
if B * 2 >= A:
  print (0)
else:
  print (A-B*2)

Fixed submission:
ABInput = str(input())
 
AB = ABInput.split(" ")
 
A = int(AB[0])
B = int(AB[1])
 
TotalCartain = B * 2
 
if TotalCartain > A or TotalCartain == A:
  print (0)
else:
  print (A-TotalCartain)

Buggy python submission (verdict: Runtime Error):
ABInput = str(input())

AB = ABInput.split(" ")

A = AB[0]
B = AB[1]

if B * 2 >= A:
  print 0
else:
  print A-B*2

Fixed submission:
ABInput = str(input())
 
AB = ABInput.split(" ")
 
A = int(AB[0])
B = int(AB[1])
 
TotalCartain = B * 2
 
if TotalCartain > A or TotalCartain == A:
  print (0)
else:
  print (A-TotalCartain)

Buggy python submission (verdict: Runtime Error):
if B * 2 >= A:
  print 0
else:
  print A-B*2

Fixed submission:
ABInput = str(input())
 
AB = ABInput.split(" ")
 
A = int(AB[0])
B = int(AB[1])
 
TotalCartain = B * 2
 
if TotalCartain > A or TotalCartain == A:
  print (0)
else:
  print (A-TotalCartain)
Buggy python submission (verdict: Runtime Error):
N = str(input())
Ds = str(input()).split(" ")
answer = 0

for di in range(len(Ds)):
  for dii in range(di):
    sum = Ds[di] + Ds[dii] 
    answer += sum

print answer

Fixed submission:
N = str(input())
Ds = str(input()).split(" ")
answer = 0
 
for di in range(len(Ds)):
  for dii in range(di+1,len(Ds)):
    sum = int(Ds[di]) * int(Ds[dii])
    answer += sum
print(answer)
Buggy python submission (verdict: Runtime Error):
Length = int(input())
inputString = input()
SpecialIndex = int(input())

for i in inputString:
  if i != inputString[SpecialIndex-1]:
    inputString[i] = "*"
print(inputString)

Fixed submission:
Length = int(input())
inputString = input()
SpecialIndex = int(input())
SpecialChar = inputString[SpecialIndex-1]
answer = ""
for i in inputString:
  if i != SpecialChar:
    answer += "*"
  else:
    answer += i
print(answer)
Buggy python submission (verdict: Runtime Error):
l = [int(input()) for _ in range(int(input))]
HIGH = max(l)
print(sum(l)-int(HIGH//2))

Fixed submission:
l = [int(input()) for _ in range(int(input()))]
print(sum(l)-int(max(l))//2)
Buggy python submission (verdict: Runtime Error):
N = int(input())
w =  [input() for i in range(N)]

valid = False

for i in range(1, N-1):
    if w[i-1][-1] == w[i][0] and len(set(w)) == len(w):
        valid = True
    else:
        valid = False

    print("Yes" if valid else "No")

Fixed submission:
A, B = map(int, input().split())
 
judge = False
for C in range(1,4):
  if (A*B*C) %2 == 1:
    judge = True
   
 
  
if judge == True:
  print("Yes")
else:
  print("No")

Buggy python submission (verdict: Runtime Error):
A, B = map(int, input().split())
 
judge = False
for c in range(1,4):
  if (A*B*C) %2 == 1:
    judge = True
   
 
  
if judge == True:
  print("Yes")
else:
  print("No")
      

Fixed submission:
A, B = map(int, input().split())
 
judge = False
for C in range(1,4):
  if (A*B*C) %2 == 1:
    judge = True
   
 
  
if judge == True:
  print("Yes")
else:
  print("No")

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

judge = False
for c in range(1,4):
  if A*B*C %2 == 1:
    judge = True
   

  
if judge == True:
  print("Yes")
else:
  print("False")
      
    

Fixed submission:
A, B = map(int, input().split())
 
judge = False
for C in range(1,4):
  if (A*B*C) %2 == 1:
    judge = True
   
 
  
if judge == True:
  print("Yes")
else:
  print("No")
Buggy python submission (verdict: Runtime Error):
# coding: utf-8
def is_unique(seq):
    return len(seq) == len(set(seq))
 
 
def main():
    n = int(input())
 
    w = []
    for i in range(n):
        w.append(input())
 
    for i in range(n-1):
        if w[i][-1] != w[i + 1][0] and not is_unique(w)::
            return 'No'
        else:
            return 'Yes'
 
if __name__ == '__main__':
    main()

Fixed submission:
# coding: utf-8
 
 
def is_unique(seq):
    return len(seq) == len(set(seq))
 
 
def main():
    n = int(input())
    shiri = True
 
    w = []
    for i in range(n):
        w.append(input())
 
    for i in range(n-1):
        if w[i][-1] != w[i + 1][0]:
            shiri = False
            break
 
    if not is_unique(w):
        shiri = False
 
    if shiri:
        print('Yes')
    else:
        print('No')
 
 
if __name__ == '__main__':
    main()

Buggy python submission (verdict: Runtime Error):
w = input().split('\n')
valid = False
for i in range(1,len(w)):
  if w[i][-1] == w[i+1][0] and len(set(w)) == len(w):
    valid = True
    return
  else:
    valid = False
   
  
  print("Yes" if valid else "No")

Fixed submission:
# coding: utf-8
 
 
def is_unique(seq):
    return len(seq) == len(set(seq))
 
 
def main():
    n = int(input())
    shiri = True
 
    w = []
    for i in range(n):
        w.append(input())
 
    for i in range(n-1):
        if w[i][-1] != w[i + 1][0]:
            shiri = False
            break
 
    if not is_unique(w):
        shiri = False
 
    if shiri:
        print('Yes')
    else:
        print('No')
 
 
if __name__ == '__main__':
    main()

Buggy python submission (verdict: Runtime Error):
w = input().split('\n')
valid = False
for i in range(1,len(w))
  if w[i][-1] == w[i+1][0] and len(set(w)) == len(w) 
      vaild = True
  else: 
      vaild = False

print("Yes" if vaild else "NO")


Fixed submission:
# coding: utf-8
 
 
def is_unique(seq):
    return len(seq) == len(set(seq))
 
 
def main():
    n = int(input())
    shiri = True
 
    w = []
    for i in range(n):
        w.append(input())
 
    for i in range(n-1):
        if w[i][-1] != w[i + 1][0]:
            shiri = False
            break
 
    if not is_unique(w):
        shiri = False
 
    if shiri:
        print('Yes')
    else:
        print('No')
 
 
if __name__ == '__main__':
    main()
Buggy python submission (verdict: Runtime Error):
O = input()
E = input()
answer = ""
i = 1
o = 0
e = 0
while i < len(E):
  if i % 2 != 0:
    answer.append(O[o])
    o += 1
  else:
    answer.append(E[e])
    e += 1
  i += 1

if len(O) - len(E) == 1:
  answer.append(O[-1])

return answer

Fixed submission:
O = input()
E = input()
answer = ""
i = 1
o = 0
e = 0
while i < len(E)+len(O)+1:
  if i % 2 != 0:
    answer += O[o]
    o += 1
  else:
    answer += E[e]
    e += 1
  i += 1

print(answer)
Buggy python submission (verdict: Runtime Error):
input_ = input().split()
if input_[0] != input_[-1]:
  return "D"
else:
  return "H"

Fixed submission:
a,_,b=input()
print("DH"[a==b])
Buggy python submission (verdict: Runtime Error):
input_ = inpur().split(",")
print(" ".join(str for i in input))

Fixed submission:
input_ = input().split(',')
print(' '.join(input_))
Buggy python submission (verdict: Runtime Error):
Title = input().split(' ')
answer = ""

for smallTitle in Title:
  answer += smallTitle[0]

return answer

Fixed submission:
Title = input().split(' ')
answer = ""
 
for smallTitle in Title:
  answer += smallTitle[0]

print(answer)
Buggy python submission (verdict: Runtime Error):
L,N = map(int, input().split())
s = sorted([input() for i in range(N)])
print("".join(s))

Fixed submission:
n,l=map(int,input().split())
s=sorted([input() for i in range(n)])
print("".join(s))

Buggy python submission (verdict: Runtime Error):
L,N = (int, input().split())
s = sorted([input() for i in range(N)])
print("".join(s))

Fixed submission:
n,l=map(int,input().split())
s=sorted([input() for i in range(n)])
print("".join(s))

Buggy python submission (verdict: Runtime Error):
L,N = (int, input().split())
s = sorted([input() for i in range(N)])
print(s,end="")

Fixed submission:
n,l=map(int,input().split())
s=sorted([input() for i in range(n)])
print("".join(s))
Buggy python submission (verdict: Runtime Error):
s,w=map(int,input().split())
if s <= w:
  print("unsafe")
 else:
  print("safe")

Fixed submission:
s,w=map(int,input().split())
if s <= w:
  print("unsafe")
else:
  print("safe")
Buggy python submission (verdict: Runtime Error):
num1 = input('整数を入力してください：')

while num1.replace('-', '').isdigit() == False or int(num1) < -100:
    print('Error')
    num1 = input('整数を入力してください：')
else:
    num1 = int(num1)
num1 = int(num1)



num2 = input('整数を入力してください：')

while num2.replace('-', '').isdigit() == False or int(num2) > 100:
    print('Error')
    num2 = input('整数を入力してください：')
else:
    num2 = int(num2)
num2 = int(num2)


plus = num1 + num2
minus = num1 - num2
times = num1 * num2

list = [plus,minus,times]

print(max(list))


Fixed submission:
num1,num2 = map(int, input().split())

plus = num1 + num2
minus = num1 - num2
times = num1 * num2

list = [plus,minus,times]

print(max(list))
Buggy python submission (verdict: Runtime Error):
k = input('整数を入力してください：')

while k.replace('-', '').isdigit() == False or int(k) > 100 or int(k) < 1:
    print('Error')
    k = input('整数を入力してください：')
else:
    k = int(k)
k = int(k)

x = input('整数を入力してください：')

while x.replace('-', '').isdigit() == False or int(x) > 100 or int(x) < 0:
    print('Error')
    x = input('整数を入力してください：')
else:
    x = int(x)
x = int(x)


result = []
for i in range(x,-k,-1):
    result.append(i)
for j in range(x+1,k):
    result.append(j)
result.sort()
print(format(result))

Fixed submission:
k,x = map(int, input().split())

for i in range(x-k+1,x+k):
    print(i, end = " ")
Buggy python submission (verdict: Runtime Error):
n = input('整数を入力してください：')

while n.isdigit() == False or int(n) < 1 or int(n) > 20:
    print('Error')
    n = input('整数を入力してください：')
else:
    n = int(n)
n = int(n)


a = input('整数を入力してください：')

while a.isdigit() == False or int(a) < 1 or int(a) > 50:
    print('Error')
    a = input('整数を入力してください：')
else:
    a = int(a)
a = int(a)

b = input('整数を入力してください：')

while b.isdigit() == False or int(b) < 1 or int(b) > 50:
    print('Error')
    b = input('整数を入力してください：')
else:
    b = int(b)
b = int(b)

train = n * a
taxi = b

expense = [train,taxi]

print(min(expense))

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

train = n * a
taxi = b

expense = [train,taxi]

print(min(expense))
Buggy python submission (verdict: Runtime Error):
n,d = map(int, input().split())


x = []
for i in range(n):
    x.append(list(map(int, input().split())))


result = 0

for i in range(n-1):
    total = 0
    for k in range(d-1):
        r = (x[i][k] - x[i+k][k]) ** 2
        total += r
    total = total ** 0.5
    if total.is_integer():
        result += 1
print(result)

Fixed submission:
n,d = map(int, input().split())


x = []
for i in range(n):
    x.append(list(map(int, input().split())))


result = 0

for i in range(n):
    for j in range(n):
        if i < j:
            dist = 0
            for k in range(d):
                dist += (x[i][k] - x[j][k]) ** 2
            dist = dist ** 0.5
            if dist.is_integer():
                result += 1
print(result)
Buggy python submission (verdict: Runtime Error):
K = int(input())
A, B = map(int, input().split())
i = A // K
nK = K
OK = False
if A-B > K:
  print('OK')
else:
  while nK =< B:
    if (nK >= A) and (nK <= B):
      OK = True
      print('OK')
      break
    nK = i * K
    i = i + 1
if OK == False:
  print('NG')

Fixed submission:
K = int(input())
A, B = map(int, input().split())
i = A // K
nK = K
OK = False
if A-B > K:
  print('OK')
else:
  while nK <= B:
    if (nK >= A) and (nK <= B):
      OK = True
      print('OK')
      break
    nK = i * K
    i = i + 1
if OK == False:
  print('NG')

Buggy python submission (verdict: Runtime Error):
K = int(input())
A, B = map(int, input().split())
i = A // K
nk = K
OK = False
if A-B >= K:
  print('OK')
else:
  while nK < B:
    if (nK >= A) and (nK <= B):
      OK = True
      print('OK')
    nK = i * K
    i = i + 1
if OK == False:
  print('NG')

Fixed submission:
K = int(input())
A, B = map(int, input().split())
i = A // K
nK = K
OK = False
if A-B > K:
  print('OK')
else:
  while nK <= B:
    if (nK >= A) and (nK <= B):
      OK = True
      print('OK')
      break
    nK = i * K
    i = i + 1
if OK == False:
  print('NG')

Buggy python submission (verdict: Runtime Error):
K = int(input())
A, B = map(int, input().split())
i = A // K
nk = K
OK = False
if A-B >= K:
  print('OK')
else:
  while nK < B:
    if (nK >= A) and (nK <= B):
      OK = True
      print('OK')
    nK = i * K
    i = i + 1
if OK = False:
  print('NG')

Fixed submission:
K = int(input())
A, B = map(int, input().split())
i = A // K
nK = K
OK = False
if A-B > K:
  print('OK')
else:
  while nK <= B:
    if (nK >= A) and (nK <= B):
      OK = True
      print('OK')
      break
    nK = i * K
    i = i + 1
if OK == False:
  print('NG')
Buggy python submission (verdict: Runtime Error):
A, B = input().split()
 
if int(A) >= 13:
  print(B)
elif int(A) <=5:
  print(str(0))
else:
  print(str(B//2))

Fixed submission:
A, B = input().split()
 
if int(A) >= 13:
  print(B)
elif int(A) <=5:
  print(str(0))
else:
  print(str(int(B)//2))

Buggy python submission (verdict: Runtime Error):
A, B = input().split()

if A >= 13:
  print(B)
elif A <=5:
  print("0")
else:
  print(str(B//2))

Fixed submission:
A, B = input().split()
 
if int(A) >= 13:
  print(B)
elif int(A) <=5:
  print(str(0))
else:
  print(str(int(B)//2))
Buggy python submission (verdict: Runtime Error):
r, D, X_1 = input().split()
r = int(r)
D = int(D)
x = int(X_1)
for i in range(10):
  print(str(x))
  x = r * X - D

Fixed submission:
r, D, X_1 = input().split()
r = int(r)
D = int(D)
x = int(X_1)
for i in range(10):
  x = r * x - D
  print(str(x))
Buggy python submission (verdict: Runtime Error):
import numpy as np
import sys
count = 0
N = int(input())
h = list(map(int, input().split()))

h = map(lambda x:  x-min(h) ,h)
count =+ min(h)
if max(h) == 0:
  return count

h = h.append(0)
while max(h) !=0:
    for i in range(len(h)+1):
        if h[i] == 0:
            continue
        else:
            for j in range(i+1,len(h)+1):
                if h[j] != 0:
                    continue
                else h[j] == 0:
                    count += 1
                    break
    h = map(lambda x:  x-1 ,h)
print(count)

Fixed submission:
count = 0
N = int(input())
h = list(map(int, input().split()))
count =+ min(h)
h = list(map(lambda x:  x-min(h) ,h))
# if max(h) == 0:
#     print(count)
h.append(0)
while max(h) != 0:
    for i in range(len(h)):
        if h[i] <= 0:
            continue
        elif h[i-1] > 0:
            continue
        else:
            for j in range(i+1,len(h)+1):
                if h[j] > 0:
                    continue
                else:
                    count += 1
                    break
    h = list(map(lambda x:  x-1 ,h))
print(count)
Buggy python submission (verdict: Runtime Error):
def add(A,B,T):
  C=T//A
  return C*B
  
A=int(input())
B=int(input())
T=int(input())
print(add(A,B,T))

Fixed submission:
def add(A,B,T):
  C=T//A
  return C*B
  
a=list(map(int,input().split()))
print(add(a[0],a[1],a[2]))