Harryxun/GPT-100-sft-dataset huggingface dataset:
Problem p03565 (python)

Fixed submission:
S = input()
T = input()
m = len(S)
n = len(T)

Sa = []

if m >= n:
    for i in range(m+1-n):
        for j in range(n):
            if S[i+j] != T[j] and S[i+j] != "?":
                break
        else:
            s = S[:i] + T + S[i+n:]
            Sa.append(s.replace("?", "a"))
            

if Sa:
    print(min(Sa))
else:
    print("UNRESTORABLE")

Buggy submission (verdict: Runtime Error):
S = input()
T = input()
m = len(S)
n = len(T)

ans = 0
if m >= n:
    for i in range(m+1-n):
        for j in range(n):
            if S[i+j] != T[j] and S[i+j] != "?":
                break
        else:
            S = S[0:i] + T + S[i+n+1:]
            ans = 1

if ans == 1:
    print(S.replace("?", "a"))
else:
    print("UNRESTORABLE")

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

sl = list(S)
tl = list(T)
n = len(tl)
w = "?" * n

ans = 0
if len(S) >= n:
    if w in S:
        ans = 1
        S.replace(w, T)
        sl = list(S)
    for i in range(n):
        if tl[i] in sl:
            j = sl.index(tl[i])
            #print(j, tl[i])
            sl2 = sl[j-i:j]
            sl2.extend(sl[j+1:j+n-i])
            #print(sl2)
            tl2 = tl[0:i]
            tl2.extend(tl[i+1:])
            #print(tl2)
            #print(sl2)
            # #print(tl)
            for k in range(len(tl2)):
                if  sl2[k] != tl2[k] and sl2[k] != "?":
                    break
                ans = 1
                sl[j-i:j] = tl2[0:i]
                sl[j+1:j+n-i] = tl[i+1:] 
#print(ans)
S = "".join(sl)
#print(S)

if ans == 1:
    A = S.replace("?", "a")
    print(A)
else:
    print("UNRESTORABLE")

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

sl = list(S)
tl = list(T)
n = len(tl)
w = "?" * n

ans = 0

if w in S:
  ans = 1
  S.replace(w, T)
  sl = list(S)
for i in range(n):
    if tl[i] in sl:
        j = sl.index(tl[i])
        try:
            sl2 = sl[j-i:j+n-i]
        except:
            continue
        #print(sl2)
        # #print(tl)
        for k in range(n):
            if  sl2[k] != tl[k] and sl2[k] != "?":
                break
            ans = 1
            sl[j-i:j+n-i] = T

S = "".join(sl)
#print(S)

if ans == 1:
    A = S.replace("?", "a")
    print(A)
else:
    print("UNRESTORABLE")

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

sl = list(S)
tl = list(T)
n = len(tl)
w = "?" * n

ans = 0

if w in S:
  ans = 1
  S.replace(w, T)
  sl = list(S)
for i in range(n):
  if tl[i] in sl:
    j = sl.index(tl[i])
    sl2 = sl[j-i:j+n-i]
    #print(sl2)
    #print(tl)
    for k in range(n):
      if  sl2[k] != tl[k] and sl2[k] != "?":
        break
      ans = 1
      sl[j-i:j+n-i] = T

S = "".join(sl)
#print(S)

if ans == 1:
    A = S.replace("?", "a")
    print(A)
else:
    print("UNRESTORABLE")
Problem p03575 (python)

Fixed submission:
N, M = [int(i) for i in input().split()]
graph = [[0]*N for i in range(N)]
vstd = [0] * N

for i in range(M):
    a, b = [int(i) for i in input().split()]
    graph[a-1][b-1] = graph[b-1][a-1] = 1
#print(*graph, sep="\n")

def dfs(v):
    vstd[v] = 1
    for v2 in range(N):
        if graph[v][v2] == 0:
            continue
        if vstd[v2] == 1:
            continue
        dfs(v2)
 
ans = 0
for i in range(N):
    for j in range(N):
        if graph[i][j] == 0:
            continue
        graph[i][j] = graph[j][i] = 0
        for k in range(N):
            vstd[k] = 0
        dfs(0)
        bridge = False
        for k in range(N):
            if vstd[k] == 0:
                bridge = True
        if bridge == True:
            ans += 1
        graph[i][j] = graph[j][i] = 1

print(ans//2)

Buggy submission (verdict: Runtime Error):
N, M = [int(i) for i in input().split()]
for j in range(M):
    a, b = [int(k) for k in input().split()]
    graph[a-1][b-1] = graph[b-1][a-1] = 1

nmax = 50
graph = [[0]*nmax for i in range(nmax)]

print(*graph)
Problem p02700 (python)

Fixed submission:
import sys 
import math
try:
	sys.stdin = open('input.txt', 'r') 
	sys.stdout = open('output.txt', 'w')
except:
	pass
input = sys.stdin.readline
for tt in range(1):
	a,b,c,d = map(int,input().split())
	if math.ceil(c/b) - math.ceil(a/d)<= 0:
		print ("Yes")
	else:
		print("No")

Buggy submission (verdict: Runtime Error):
import sys 
import math
try:
	sys.stdin = open('input.txt', 'r') 
	sys.stdout = open('output.txt', 'w')
except:
	pass
input = sys.stdin.readline
for tt in range(1):
	a,b,c,d = map(int,input().split())
	elif math.ceil(c/b) - math.ceil(a/d)<= 0:
		print ("Yes")
	else:
		print("No")
Problem p02717 (python)

Fixed submission:
for _ in range(1):
	a,b,c = map(int,input().split())
	print(c,a,b)

Buggy submission (verdict: Runtime Error):
for _ in range(1):
	a,b,c = map(int,input().split())
    print(c,a,b)
Problem p03455 (python)

Fixed submission:
a,b = map(int,input().split())
 
product = a*b
if product%2==0:
    print("Even")
elif product%2==1:
    print('Odd')

Buggy submission (verdict: Runtime Error):
A = input().split
a,b = map(int,A)
 
product = a*b
if product%2==0:
    print("Even")
elif product%2==1:
    print('Odd')

Buggy submission (verdict: Runtime Error):
A =list(input().split)
a,b = map(int(),A)

product = a*b
if product%2==0:
    print("Even")
elif product%2==1:
    print('Odd')

Buggy submission (verdict: Runtime Error):
product = a*b
if product%2==0:
    print("Even")
elif product%2==1:
    print('Odd')

Buggy submission (verdict: Runtime Error):
product = a*b
if product%2==0:
    print("Even")
elif product%2==1:
    print('Odd')

Buggy submission (verdict: Runtime Error):
product = a*b

if product%2==0:
    print("Even")
else:
    print('Odd')

Buggy submission (verdict: Runtime Error):
product = a*b

if product%2==0:
    print("Even")
else:
    print('Odd')

Buggy submission (verdict: Runtime Error):
product = a*b
divide_type = type(product/2)

if divide_type == int:
    print("Even")
if divide_type==float:
    print('Odd')
Problem p03478 (python)

Fixed submission:
#ANS
input_all = input()
input_N = input_all.split()[0] #str型で読み込む
A,B = int(input_all.split()[1]),int(input_all.split()[2]) #int型で読み込む
input_list = [int(input_N[i]) for i in range(len(input_N))]

e = input_list[-1]
if len(input_list)>1:
    d = input_list[-2]
    if len(input_list)>2:
        c = input_list[-3]
        if len(input_list)>3:
            b = input_list[-4]
            if len(input_list)>4:
                a = input_list[-5]

count = 0
for i in range(int(input_N)+1):
    sum_all = 0
    i_str = str(i)
    for j in range(len(i_str)):
        sum_all += int(i_str[j])
    if A<=sum_all:
        if sum_all<=B:
            count += i
print(count)

Buggy submission (verdict: Runtime Error):
#ANS-3
input_N,A,B = input_all.split()[0],int(input_all.split()[1]),int(input_all.split()[2])

count = 0
for i in range(int(input_N)+1):
    sum_all = 0
    i_str = str(i)
    for j in range(len(i_str)):
        sum_all += int(i_str[j])
    if A<=sum_all:
        if sum_all<=B:
            count += i
            
print(count)
Problem p03493 (python)

Fixed submission:
s = str(input())
s_list = [int(s[0]),int(s[1]),int(s[2])]
count = 0
for i in s_list:
    if i==1:
        count +=1
print(count)

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

iter_num_list = []
for a in A_list:
    count = 0
    while a%2 == 0:
        a = a/2
        count += 1
    iter_num_list.append(count)
ans = sorted(iter_num_list)[0]
print(ans)

Buggy submission (verdict: Runtime Error):
#(問3)ANS-1
iter = map(int,input().split())
all_list = []
for i in iter:
    all_list.append(i)
N = all_list[0]
A_list = all_list[1:]

iter_num_list = []
for a in A_list:
    count = 0
    while a%2 == 0:
        a = a/2
        count += 1
    iter_num_list.append(count)
ans = sorted(iter_num_list)[0]
print(ans)
Problem p03494 (python)

Fixed submission:
#(問3)ANS-1
import sys
lines = sys.stdin.readlines()
N = lines[0]
N = N.strip()
A = lines[1]
A_iter = map(int,A.split()) #イテレータを生成
A_list = []
for i in A_iter:
    A_list.append(i)

iter_num_list = []
for a in A_list:
    count = 0
    while a%2 == 0:
        a = a/2
        count += 1
    iter_num_list.append(count)
ans = sorted(iter_num_list)[0]
print(ans)

Buggy submission (verdict: Runtime Error):
#(問3)ANS
iter = map(int,input().split())
all_list = []
for i in iter:
    all_list.append(i)
N = all_list[0]
A_list = all_list[1:]

iter_num_list = []
for a in A_list:
    count = 0
    while a%2 == 0:
        a = a/2
        count += 1
    iter_num_list.append(count)
ans = min(iter_num_list)
print(ans)
Problem p02681 (python)

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

Buggy submission (verdict: Runtime Error):
s, t = input().strip().split()
if s == t[:-1]:
  print("Yes")
else:
  print("No")
Problem p02684 (python)

Fixed submission:
n, k = [int(x) for x in input().split()]
a = [int(x)-1 for x in input().split()]
assert len(a) == n
current = 0
visited = [-1] * n
visited[0] = 0
for i in range(1, k):
  current = a[current]
  if visited[current] == -1:
    visited[current] = i
  else:
    pre = visited[current]
    count = (k - pre) % (i - pre) + pre
    print(visited.index(count)+1)
    break
else:
  print(a[current]+1)

Buggy submission (verdict: Runtime Error):
import numpy as np
from itertools import product
n, m, x = [int(x) for x in input().split()]
a = np.stack([np.array(input().split(), dtype=int) for _ in range(n)])
tot = np.sum(a, axis=0)
if min(tot[1:]) < x:
    print(-1)
    exit(0)
cost = tot[0]
whole = np.array(list(product([0,1],repeat=n)), dtype=bool)[1:-1]
for flag in whole:
    tot = np.sum(a[flag], axis=0)
    if min(tot[1:]) >= x and tot[0] < cost:
        cost = tot[0]
print(cost)

Buggy submission (verdict: Runtime Error):
n, k = [int(x) for x in input().split()]
a = [int(x)-1 for x in input().split()]
assert len(a) == n
current = 0
visited = [-1] * n
visited[0] = 0
for i in range(1, k):
  current = a[current]
  if visited[current] == -1:
    visited[current] = i
  else:
    pre = visited[current]
    count = (k - pre) % (i - pre) + pre
    print(visited.index(count)+1)
else:
  print(a[current]+1)

Buggy submission (verdict: Runtime Error):
n, k = [int(x) for x in input().strip().split()]
a = [int(x)-1 for x in input().strip().split()]
assert len(a) == n
current = 0
visited = [-1] * n
visited[0] = 0
way = [0]
for i in range(1, k):
  current = a[current]
  if visited[current] == -1:
    visited[current] = i
  else:
    pre = visited[current]
    count = (k - pre) % (i - pre) + pre
    print(visited.index(count)+1)
else:
  print(a[current]+1)
Problem p02702 (python)

Fixed submission:
def main():
    mod = 2019
    count = [0] * 2019
    count[0] = 1
    s = input().strip()
    digit = 1
    current = 0
    for c in s[::-1]:
        current = (current + int(c) * digit) % mod
        count[current] += 1
        digit = digit * 10 % mod
    return sum([n * (n - 1) // 2 for n in count if n > 1])


print(main())

Buggy submission (verdict: Runtime Error):
import numpy as np


def count_multi(s, d):
  a = np.array([int(c) for c in s], dtype=np.uint16)
  # assume d >= 10
  m = a
  # s not include 0
  count = 0
  while len(m) > 1:
    a = a[1:]
    m = (m[:-1]*10 + a) % d
    count += np.count_nonzero(m == 0)
  return count

print(count_multi(input().strip(), 2019)
Problem p03047 (python)

Fixed submission:
N,K = map(int, input().split())
print(N-K+1)

Buggy submission (verdict: Runtime Error):
N = int(input())
S = 0

for i in range(N):
   S = S+i+1 if N//(i+1)==N%(i+1) else S

print(S)

Buggy submission (verdict: Runtime Error):
N = int(input())
K = int(input())
print(N-K+1)

Buggy submission (verdict: Runtime Error):
N = int(input())
K = int(input())
print(N-K)
Problem p03062 (python)

Fixed submission:
N = int(input())
A = list(int(i) for i in input().split())
count_m = 0
count_z = 0

for i in A:
  if i < 0:
    count_m += 1
  elif i == 0:
    count_z += 1

A_abs = [abs(i) for i in A]
if count_m%2 == 0 or (count_m+count_z)%2 == 0:
  print(sum(A_abs))
  
else:
  A_min = A_abs.index(min(A_abs))
  A_abs[A_min] = A_abs[A_min]*(-1)
  print(sum(A_abs))

Buggy submission (verdict: Runtime Error):
N = int(input())
A = list(int(i) for i in input().split())
count_m = 0
count_z = 0

for i in A:
  if i < 0:
    count_m += 1
  elif i == 0:
    count_z += 1

A_abs = [abs(i) for i in A]
if count_m%2 == 0 or (count_m+count_z)%2 == 0:
  print(sum(A_abs))
  
else:
  A_min = A.index(min(A_abs))
  A_abs[A_min] = A_min[A_min]*(-1)
  print(sum(A_abs))

Buggy submission (verdict: Runtime Error):
N = int(input())
A = list(int(i) for i in input().split())
count_m = 0
count_z = 0

for i in A:
  if i < 0:
    count_m += 1
  elif i == 0:
    count_z += 1

A_abs = [abs(i) for i in A]
if count_m%2 == 0 or (count_m+count_z)%2 == 0:
  print(sum(A_abs))
  
else:
  A_min = A.index(min(A_abs))
  A_abs[A_min] = A[A_min]*(-1)
  print(sum(A_abs))

Buggy submission (verdict: Runtime Error):
N = int(input())
A = list(int(i) for i in input().split())
count_m = 0
count_z = 0

for i in A:
  if i < 0:
    count_m += 1
  elif i == 0:
    count_z += 1

A_abs = [abs(i) for i in A]
if count_m%2 == 0 || (count_m+count_z)%2 == 0:
  print(sum(A_abs))
  
else:
  A_min = A.index(min(A_abs))
  A_abs[A_min] = A[A_min]*(-1)
  print(sum(A_abs))

Buggy submission (verdict: Runtime Error):
N = int(input())
A = list(int(i) for i in input().split())
count_m = 0
count_z = 0

for i in A:
  if i < 0:
    count_m += 1
  elif i == 0:
    count_z += 1

A_abs = [abs(i) for i in A]
if count_m%2 == 0 || count_m+count_z%2 == 0:
  print(sum(A_abs))
  
else:
  A_min = A.index(min(A_abs))
  A_abs[A_min] = A[A_min]*(-1)
  print(sum(A_abs))

Buggy submission (verdict: Runtime Error):
N = int(input())
A = list(int(i) for i in input().split())
count = 0

for i in A:
  if i <= 0:
    count += 1

A_abs = [abs(i) for i in A]
if count%2 == 0:
  print(sum(A_abs))
  
else:
  A_min = A.index(min(A_abs))
  A_abs[A_min] = A[A_min]*(-1)
  print(sum(A_abs))
Problem p02741 (python)

Fixed submission:

def main():
    K = int(input())
    List = [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]
    print(List[K-1])

if __name__ == '__main__':
    main()

Buggy submission (verdict: Runtime Error):


def get_str(st, i, len_val):
    ret = '?'*len_val
    for s in st:
        ret[i] = s
        i += 1
    return ret

def main():
    a = input()
    b = input()
    c = input()


    total_len = 6001

    def f(a1, b1, c1):
        nonlocal total_len
        for A,B,C in zip(a1,b1,c1):
            if len(set([char for char in [A,B,C] if char != '?'])) > 1:
                return False
        while a1[-1] != '?':
            a1 = a1[:-1]
        if len(a1) < total_len:
            total_len = len(a1)
        return True

    a_temp = get_str(a,0,len(a)+len(b)+len(c))

    for i in range(len(a)+len(b)+len(c)):
        try:
            b_temp = get_str(b,i,len(a)+len(b)+len(c))
            for j in range(len(a)+len(b)+len(c)):
                try:
                    c_temp = get_str(c,j,len(a)+len(b)+len(c))

                except:
                    pass
        except:
            pass

if __name__ == '__main__':
    main()

Buggy submission (verdict: Runtime Error):
def main():
    a,b,c = list(map(int,input().split(' ')))
    #a,b,c = list(map(lambda x:abs(int(x)),input().split(' ')))
    # if (a**0.5 + b**0.5) < (c**0.5):
    #     print('Yes')
    # else:
    #     print('No')

    if c < 0:
        print('No')
        return
    if (4*a*b) < ((c-a-b)**2):
        print('Yes')
    else:
        print('No')

if __name__ == '__main__':
    main()

Buggy submission (verdict: Runtime Error):
def main():
    a,b,c = list(map(int,input().split(' ')))
    #a,b,c = list(map(lambda x:abs(int(x)),input().split(' ')))
    # if (a**0.5 + b**0.5) < (c**0.5):
    #     print('Yes')
    # else:
    #     print('No')

    if (4*a*b) < ((c-a-b)**2) and c>=0:
        print('Yes')
    else:
        print('No')

if __name__ == '__main__':
    main()

Buggy submission (verdict: Runtime Error):
def main():
    a,b,c = list(map(int,input().split(' ')))
    #a,b,c = list(map(lambda x:abs(int(x)),input().split(' ')))
    # if (a**0.5 + b**0.5) < (c**0.5):
    #     print('Yes')
    # else:
    #     print('No')

    if (4*a*b) < ((c-a-b)**2) and c>=0:
        print('Yes')
    else:
        print('No')

if __name__ == '__main__':
    main()
Problem p02747 (python)

Fixed submission:
#!/usr/bin/python
# coding: UTF-8

def main():
    arg = input()
    if arg in ['hi'*i for i in range(1,6)]:
        print('Yes')
    else:
        print('No')

if __name__=='__main__':
    main()

Buggy submission (verdict: Runtime Error):
#!/usr/bin/python
# coding: UTF-8

def main():
    A,B,M = list(map(int, input().split(' ')))
    a_list = list(map(int, input().split(' ')))
    b_list = list(map(int, input().split(' ')))

    price_list = 2*10**5
    for i in range(M):
        temp = list(map(int, input().split(' ')))
        if price_list > a_list[temp[0]-1] + b_list[temp[1]-1] - temp[2]:
            price_list = a_list[temp[0]-1] + b_list[temp[1]-1] - temp[2]

    lower = min(a_list) + min(b_list)
    if lower < price_list:
        print(lower)
    else:
        print(price_list)

if __name__=='__main__':
    main()

Buggy submission (verdict: Runtime Error):
import sys

def main(arg):

    if arg[0] in ['hi'*i for i in range(1,6)]:
        print('Yes')
    else:
        print('No')

if __name__=='__main__':
    main(sys.argv[1:])
Problem p02928 (python)

Fixed submission:
import sys

def process(data):
	count1 = 0
	count2 = 0

	N = int(data[0][0])
	K = int(data[0][1])
	A = list(map(int, data[1]))

	for i in range(len(A)-1):
		for j in range(i+1, len(A)):
			if A[i] > A[j]:
				count1 += 1
	A.reverse()
	
	for i in range(len(A)-1):
		for j in range(i+1, len(A)):
			if A[i] > A[j]:
				count2 += 1	

	count1 = count1 * K*(K+1)/2
	count2 = count2 * (K-1)*K/2

	count = count1 + count2

	count = count % (10**9+7)
	return count



def main():
	d = []
	for i in range(2):
		data = raw_input()
		data = data.split(" ")
		d.append(data)
	print(process(d))

if __name__ == '__main__':
    main()

Buggy submission (verdict: Runtime Error):
import sys

def process(data):
	count = 0

	N = int(data[0][0])
	K = int(data[0][1])
	A = list(map(int, data[1])) * K

	for i in range(len(A)-1):
		for j in range(i+1, len(A)):
			if A[i] > A[j]:
				count += 1

	count = count % (10**9+7)
	return count



def main():
	d = []
	for i in range(2):
		data = raw_input()
		data = data.split(" ")
		d.append(data)
	print(process(d))

if __name__ == '__main__':
    main()
Problem p03060 (python)

Fixed submission:
n = int(input())

value = list(map(int, input().split()))
cost = list(map(int, input().split()))

ans = 0
for j in range(n):
    if value[j] -cost[j] >0:
            ans +=value[j] - cost[j]

print(ans)

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

value = list(map(int(input().split()))
cost = list(map(int(input().split()))

ans = 0
for j in range(n):
    if value[j] -cost[j] >0:
            ans +=value[j] - cost[j]

print(ans)

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

value = list(map(int(input().split()))
cost = list(map(int(input().split()))

ans = 0
for j in range(n):
    if value[j] -cost[j] >0:
            ans +=value[j] - cost[j]

print(ans)
Problem p03111 (python)

Fixed submission:
N,A,B,C = map(int,input().split())
l = [int(input()) for i in range(N)]
inf = 10**9
def dfs(cur,a,b,c):
    if cur == N:
        return abs(a - A) + abs(b - B) + abs(c - C) - 30 if min(a, b, c) > 0 else inf
    ret0 = dfs(cur+1,a,b,c)
    ret1 = dfs(cur+1,a+l[cur],b,c) + 10
    ret2 = dfs(cur+1,a,b+l[cur],c) + 10
    ret3 = dfs(cur+1,a,b,c+l[cur]) + 10
    
    return min(ret0,ret1,ret2,ret3)
 
print(dfs(0,0,0,0))

Buggy submission (verdict: Runtime Error):
N, A, B, C = map(int, input().split())
l = list(int(input()) for i in range(N))
inf = 10**9

    def dfs(cur,a,b,c):
        if cur == N:
            return abs(a - A) + abs(b - B) + abs(c - C) - 30 if min(a, b, c) > 0 else inf
        ret0 = dfs(cur+1,a,b,c)
        ret1 = dfs(cur+1,a+l[cur],b,c) + 10
        ret2 = dfs(cur+1,a,b+l[cur],c) + 10
        ret3 = dfs(cur+1,a,b,c+l[cur]) + 10
    
        return min(ret0,ret1,ret2,ret3)
 
print(dfs(0,0,0,0))

Buggy submission (verdict: Runtime Error):
N, A, B, C = map(int, input().split())
l = list(int(input()) for i in range(n))
inf = 10**9

    def dfs(cur,a,b,c):
        if cur == N:
            return abs(a - A) + abs(b - B) + abs(c - C) - 30 if min(a, b, c) > 0 else inf
        ret0 = dfs(cur+1,a,b,c)
        ret1 = dfs(cur+1,a+l[cur],b,c) + 10
        ret2 = dfs(cur+1,a,b+l[cur],c) + 10
        ret3 = dfs(cur+1,a,b,c+l[cur]) + 10
    
        return min(ret0,ret1,ret2,ret3)
 
print(dfs(0,0,0,0))
Problem p03145 (python)

Fixed submission:
ab, bc, ca = map(int, input().split())
S = int((ab * bc) /2)
print(S)

Buggy submission (verdict: Runtime Error):
ab, bc, ca = map(int, input().split())
5 12 13
S = int((ab * bc) /2)

print(S)
Problem p03238 (python)

Fixed submission:
n = int(input())

if n == 1:
    print("Hello World")
elif n ==2:
    a = int(input())
    b = int(input())
    ans = a+b
    print(ans)

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

if n == 1:
    print("Hello World")
elif n ==2:
    a, b = map(int, input().split())
    ans = a+b
    print(ans)

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

if n == 1:
    print("Hello World")
else:
    a, b = map(int, input().split())
    ans = a+b
    print(ans)

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

if n == 1:
    print("Hello World")
else:
    a, b = map(int, input().split())
    ans = a+b
    print(ans)

Buggy submission (verdict: Runtime Error):
n = input()

if n == 1:
    print("HEllo World")
else:
    a, b = map(int, input().split())
    ans = a+b
    print(ans)
Problem p03260 (python)

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

ans1 = a * b
ans2 = a* b * 2
ans3 = a * b* 3

if ans1%2 == 1:
    print('Yes')
    exit
elif ans2%2 ==1:
    print('Yes')
    exit
elif ans2%2 ==1:
    print('Yes')
    exit
else:
    print("No")

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

ans1 = a * B
ans2 = a* b * 2
ans3 = a * b* 3

if ans1%2 == 1:
    print('Yes')
    exit
elif ans2%2 ==1:
    print('Yes')
    exit
elif ans2%2 ==1:
    print('Yes')
    exit
else:
    print("No")

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

ans1 = a * B
ans2 = a* b * 2
ans3 = a * b* 3

if ans1%2 == 1:
    print('Yes')
elif ans2%2 ==1:
    print('Yes')
elif ans2%2 ==1:
    print('Yes')
else:
    print("No")
Problem p03282 (python)

Fixed submission:
S = list(input())
K = int(input())

res =0
for i in range(K):
    if S[i] == '1':
        if i == K-1:
            res = 1
        else:
            continue
    else:
        res = S[i]
        break
print(res)

Buggy submission (verdict: Runtime Error):
S = list(input())
K = int(input())

for i in range(K):
    if S[i] == '1':
        if i == K:
            res = 1
        else:
            continue
    else:
        res = S[i]
        break
print(res)
Problem p03324 (python)

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

if n != 100:
    if d == 0:
        print(n)
    elif d == 1:
        print(n * 100)
    else :
        print(n * 10000)
else:
    if d == 0:
        print(101)
    elif d == 1:
        print(10100)
    else :
        print(1010000)

Buggy submission (verdict: Runtime Error):
if d == 0:
        print(n)
    elif d == 1:
        print(n * 100)
    else :
        print(n * 10000)
Problem p03211 (python)

Fixed submission:
s = input()

ans = 10000
index = 0
for i in range(len(s)-2):
    a = 100 * int(s[i])
    b = 10 * int(s[i+1])
    c = int(s[i+2])
    hog = a + b + c
    tmp = abs(hog - 753)
    if ans > tmp:
        ans = tmp

print(ans)

Buggy submission (verdict: Runtime Error):
s = input()

a = 10000
index = 0
for i in range(len(s)):
    n = 100 * int(s[i]) + 10 * int(s[i+1]) + int(s[i+2])
    tmp = abs(n - 753)
    if a > tmp:
        a = tmp
    if i == (len(s) - 2 ):
        break

print(a)