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

Fixed submission:
n=int(input())
if n == 1:
    print("Hello World")
else:
    a=int(input())
    b=int(input())
    print(a+b)

Buggy submission (verdict: Runtime Error):
n=int(input())
a=int(input())
b=int(input())
if n == 2:
    print(a+b)
else:
    print("Hello World")

Buggy submission (verdict: Runtime Error):
n=int(input())
a=int(input())
b=int(input())
if n == 1:
    print("Hello World")
else:
    print(a+b)
Problem p03292 (python)

Fixed submission:
*a,=map(int,input().split())
print(max(a)-min(a))

Buggy submission (verdict: Runtime Error):
# A - Task Scheduling Problem
*a=map(int,input().split())
print(max(a)- min(a)
Problem p03323 (python)

Fixed submission:
a,b=map(int,input().split())
if a>8 or b>8:
  print(":(")
else:
  print("Yay!")

Buggy submission (verdict: Runtime Error):
a,b=map(int,input().split())
if a or b => 9:
  print(":(")
else:
  print("Yay!")
Problem p02717 (python)

Fixed submission:
input_list = input().split()
a = int(input_list[2])
b = int(input_list[0])
c = int(input_list[1])
print("{} {} {}".format(a, b, c))

Buggy submission (verdict: Runtime Error):
input_list = input().split()
a = int(input_list[2])
b = int(input_list[0])
c = int(input_list[1])
print("{} {} {}".format(a, b, c)
Problem p02719 (python)

Fixed submission:
import numpy as np
n_k = [int(i) for i in input().split()]
n = n_k[0]
k = n_k[1]
r = n % k
r_1 = abs(r - k)
min = np.array([r, r_1]).min()
print(min)

Buggy submission (verdict: Runtime Error):
n_k = [int(i) for i in input().split()]
n = n_k[0]
k = n_k[1]
r = n % k
r_1 = abs(r - k)
min = np.array([r, r_1]).min()
print(min)
Problem p03000 (python)

Fixed submission:
a = input().split()
n = int(a[0])
x = int(a[1])
l_str_list = input().split()
d = 0
answer = n + 1

for i in range(n):
  d += int(l_str_list[i])
  if d > x:
    answer = i + 1
    break
  if d == x:
    answer = i + 2
    break
print(answer)

Buggy submission (verdict: Runtime Error):
a = input().split()
n = int(a[0])
x = int(a[1])
l_str_list = input().split()
d = 0
answer = 0

for i in n:
  d += int(l_str_list[i])
  if d > x:
    answer = i + 1
    break;
print(answer)
Problem p03005 (python)

Fixed submission:
x = input().split()
n = int(x[0])
k = int(x[1])

if k == 1:
    print("0")

else:
    print(n - k)

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

if k == 1:
    print("0")

else:
    print(n - k)

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

diff = n - k

if k == 1:
    print("0")

print(diff)
Problem p02717 (python)

Fixed submission:
x,y,z = input().split(" ")
print(z,x,y)

Buggy submission (verdict: Runtime Error):
x,y,z = input().split
print(z,x,y)

Buggy submission (verdict: Runtime Error):
x,y,z = map(int,input().split)
print(z,x,y)

Buggy submission (verdict: Runtime Error):
x,y,z = map(int,input().split)
new_list = [z,x,y]
print((" ").join(new_list))
Problem p02717 (python)

Fixed submission:
x, y, z = [int(i) for i in input().split()]
x, y = y, x
x, z = z, x
print(x, y, z)

Buggy submission (verdict: Runtime Error):
x, y, z = [int(i) for i in input().split()]
x, y = y, x
x, z = z, x
print(f'{x} {y} {z}')

Buggy submission (verdict: Runtime Error):
x, y, z = [int(i) for i in input().split()]
x, y = y, x
x, z = z, x
print(f'{x} {y} {z}'
Problem p02719 (python)

Fixed submission:
n, k = [int(i) for i in input().split()]

if n >= k:
    result = min(n % k, k - (n % k))
elif 2 * n >= k > n:
    n = abs(k - n)
    result = n
else:
    result = n

print(result)

Buggy submission (verdict: Runtime Error):
n, k = [int(i) for i in input().split()]

result = min(n % k, k - (n % k), k % n, n - (k % n))

print(result)

Buggy submission (verdict: Runtime Error):
n, k = [int(i) for i in input().split()]
result = n % abs(n - k)
print(result)

Buggy submission (verdict: Runtime Error):
n, k = [int(i) for i in input().split()]
while true:
    if abs(n - k) < n:
        n = abs(n - k)
    else:
        break
print(n)

Buggy submission (verdict: Runtime Error):
n, k = [int(i) for i in input().split()]
for range(n):
	if abs(n - k) < n:
        n = abs(n-k)
print(n)
Problem p02717 (python)

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

Buggy submission (verdict: Runtime Error):
a, b, c = list(map(int, input()))
print(c, a, b)
Problem p02780 (python)

Fixed submission:
import numpy as np

N, M = list(map(int, input().split()))
num_array = np.cumsum(list(map(lambda x: (x+1)/2, list(map(int, input().split())))))

max_exp = num_array[M-1]
for i in range(len(num_array)-M):
    tmp = num_array[i+M] - num_array[i]
    if max_exp < tmp:
        max_exp = tmp

print(max_exp)

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

max_exp = 0
for i in range(len(num_array) - M + 1):
    tmp = sum(processed[i:i+M])
    if max_exp < tmp:
        max_exp = tmp

print((max_exp+1)*3/2)
Problem p02783 (python)

Fixed submission:
import math
input_line = input().split()
H, A = map(int, input_line)
print(math.ceil(H/A))

Buggy submission (verdict: Runtime Error):
import math
input_line = input().split()
H, A = map(int, input_line())
print(math.ceil(H/A))
Problem p02717 (python)

Fixed submission:
A,B,C = [int(i) for i in input().split(' ')]


A, B = B, A
A, C = C, A

print('{} {} {}'.format(A, B, C))

Buggy submission (verdict: Runtime Error):
A, B = B, A
A, C = C, A

print(f'{A} {B} {C}')

Buggy submission (verdict: Runtime Error):
A,B,C = input()
A, B = B, A
A, C = C, A

print(f'{A} {B} {C}')

Buggy submission (verdict: Runtime Error):
A,B,C = [int(i) for i in input().split(' ')]


A, B = B, A
A, C = C, A

print(f'{A} {B} {C}')

Buggy submission (verdict: Runtime Error):
A,B,C = [int(i) for i in input().split(' ')]


temp = A
A = B
B = temp

temp = A
A = C
C = temp

print(f'{A} {B} {C}')

Buggy submission (verdict: Runtime Error):
A,B,C = [int(i) for i in input().split(' ')]

temp = A
A = B
B = temp

temp = A
A = C
C = temp

print(f'{A} {B} {C}')

Buggy submission (verdict: Runtime Error):
A,B,C = [int(i) for i in input().split(' ')]

temp = A
A = B
B = temp
temp = A
A = C
C = temp

print(f'{A} {B} {C}')

Buggy submission (verdict: Runtime Error):
A , B, C = int(input()).split(' ')
temp = 0
temp = A
A = B
B = temp
temp = A
A = C
C = temp
print(f'{A} {B} {C}')
Problem p02718 (python)

Fixed submission:
N,M = [int(i) for i in input().split()]

items = [int(i) for i in input().split()]
items.sort(reverse=True)
total = sum(items)

flag = 1
for i in range(M):
  if total / (4 * M) <= items[i]:
    pass
  else:
    flag = 0
if flag:
  print('Yes')
else:
  print('No')

Buggy submission (verdict: Runtime Error):
N,M = [int(i) for i in input().split()]

items = [int(i) for i in input().join(' ')]
items.sort()
total = sum(items)

flag = 1
for i in range(M):
  if 1 // (4 * M) >= items[i]:
    pass
  else:
    flag = 0
if not flag:
  print('Yes')
else:
  print('No')

Buggy submission (verdict: Runtime Error):
a = [int(i) for i in input().join(' ')]
N = a[0]
M = a[1]

items = [int(i) for i in input().join(' ')]
items.sort()
total = sum(items)

flag = 1
for i in range(M):
  if 1 // (4 * M) >= items[i]:
    pass
  else:
    flag = 0
if not flag:
  print('Yes')
else:
  print('No')

Buggy submission (verdict: Runtime Error):
[int(i) for i in input().join(' ')]
N = input()
M = input()

items = [int(i) for i in input().join(' ')]
items.sort()
total = sum(items)

flag = 1
for i in range(M):
  if 1 // (4 * M) >= items[i]:
    pass
  else:
    flag = 0
if not flag:
  print('Yes')
else:
  print('No')

Buggy submission (verdict: Runtime Error):
N, M= int(input().join(' '))

items = [int(i) for i in input().join(' ')]
items.sort()
total = sum(items)

flag = 1
for i in range(M):
  if 1 // (4 * M) >= items[i]:
    pass
  else:
    flag = 0
if not flag:
  print('Yes')
else:
  print('No')

Buggy submission (verdict: Runtime Error):
N, M= int(input().join(' '))

items = [i for i in input().join(' ')]
items.sort()
total = sum(items)

flag = 1
for i in range(M):
  if 1 // (4 * M) >= items[i]:
    pass
  else:
    flag = 0
if not flag:
  print('Yes')
else:
  print('No')

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

items = [i for i in input().join(' ')]
items.sort()
total = sum(items)

flag = 1
for i in range(M):
  if 1 // (4 * M) >= items[i]:
    pass
  else:
    flag = 0
if not flag:
  print('Yes')
else:
  print('No')
Problem p02719 (python)

Fixed submission:
N, K = [int(i) for i in input().split(' ')]

def res():
  if N == K:
    return 0
  elif N > K:
    return N % K if K - (N % K) > (N % K) else K - (N % K)
  else :
    return abs(N - K) if abs(N - K) < abs(abs(N-K) - K) else abs(abs(N-K) - K)

print(res())

Buggy submission (verdict: Runtime Error):
N, K = [int(i) for i in input().split(' ')]

prev = N

if N == 0:
  print( N)
else:
  while True:
    if prev == 0:
      print(prev)
      break
    elif abs() >= prev:
      print(prev)
      break
    else
      N = abs()
      prev = N

Buggy submission (verdict: Runtime Error):
N, K = [int(i) for i in input().split(' ')]

min_value = 0

count = 0
while True:
  if min_value < abs(N - K):
    count =+ 1
    if count > 1:
	    break
    else:
		N = abs(N - K)
		min_value = N		
  else:
	N = abs(N - K)
	min_value = N
    
print(min_value)

Buggy submission (verdict: Runtime Error):
N, K = [int(i) for i in input().split(' ')]

min1 = 0
prev = 0

while True:
  if prev < abs(N - K):
    break
  else:
    min1 = abs(N - K)
	N = abs(N - K)
	prev = min1


print(prev)

Buggy submission (verdict: Runtime Error):
N, K [int(i) for i in input().split(' ')]

min = 0
prev = 0

while abs(N - K) > prev:
  min = abs(N - K)
  prev = min

print(min)
Problem p03071 (python)

Fixed submission:
A, B = [int(i) for i in input().split(' ')]
     
def f():
    res = 0
    if A > B and A - 1 > B:
        res = A + A - 1
    elif B > A and B - 1 > A:
        res = B + B - 1
    else:
        res = A + B
    return res
print(f())

Buggy submission (verdict: Runtime Error):
A, B = [int(i) for i input().split(' ')]
     
def f():
	res = 0
    if A > B and A - 1 > B:
    	res += A + A - 1
    elif B > A and B - 1 > A:
    	res += B + B - 1
    else:
    	res = A + B
    return res
f()
Problem p02718 (python)

Fixed submission:
a,b = map(int, input().split())
List = list(map(int, input().split()))
c = sum(List)
List = sorted(List)[::-1]
d = List[b-1]
if d < c/4/b:
	print("No")
else:
	print("Yes")

Buggy submission (verdict: Runtime Error):
a,b = map(int, input().split())
List = list(map(int, input().split()))
c = sum(List)
List = sorted(List)[::-1]
d = List(b-1)
if d < c/4/b:
	print("No")
else:
	print("Yes")

Buggy submission (verdict: Runtime Error):
a,b = map(int, input().split())
List = list(map(int, input().split()))
c = sum(List)
List = sorted(List)[::-1]
d = List(b-1)
if d < c/4/b;
	print("No")
elif
	print("Yes")
Problem p04029 (python)

Fixed submission:
a=int(input())
s=a*(a+1)/2
print(int(s))

Buggy submission (verdict: Runtime Error):
a=int(input())
s=o
for i in range(1,a+1,1):
    s+=i
print(s)

Buggy submission (verdict: Runtime Error):
a=int(input())
s=o
for i in range(1,a+1,1):
    s+=i
print(s)
Problem p04043 (python)

Fixed submission:
A = list(map(int, input().split()))
A =sorted(A)
if A[0]==5 and A[1]==5 and A[2]==7:
  print("YES")
else:
  print("NO")

Buggy submission (verdict: Runtime Error):
A = list(map(int, input().split()))
A =sorted(A)
if A[0]=5 and A[1]=5 and A[2]=7:
  print("YES")
else:
  print("NO")

Buggy submission (verdict: Runtime Error):
A = list(map(int, input().split()))
if max(A)=7 and mean(A)=5 and min(A)=5:
  print("YES")
else:
  print("NO")

Buggy submission (verdict: Runtime Error):
a,b,c = map(int, input().split())
if max(a,b,c)=7 and mean(a,b,c)=5 and min(a,b,c)=5:
  print("YES")
else:
  print("NO")

Buggy submission (verdict: Runtime Error):
a,b,c=int(input().split())
if max(a,b,c)=7 and mean(a,b,c)=5 and min(a,b,c)=5:
  print("YES")
else:
  print("NO")

Buggy submission (verdict: Runtime Error):
a,b,c=input().split()
if max(a,b,c)=7 and mean(a,b,c)=5 and min(a,b,c)=5:
  print("YES")
else:
  print("NO")
Problem p03059 (python)

Fixed submission:
# -*- coding: utf-8 -*-
a, b, t = map(int, input().split())

t = (t+0.5)//a


bbb = int(t*b)

print(bbb)

Buggy submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
a, b, t = map(int, input().split())

# 何回生産出来るか
p = (t+0.5)//a

anc = int(p*b)

print(ans)
Problem p03061 (python)

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

# 最大公約数
def gcd(a,b):
    if b==0:return a
    return gcd(b,a%b)

# 入力
n = int(input())
a = list(map(int, input().split()))

# 累積GCD
left = [0]*(n+1)
right = [0]*(n+1)
for i in range(n):
    left[i+1] = gcd(left[i], a[i])
for i in reversed(range(n)):
    right[i] = gcd(right[i+1], a[i])

# print(left)
# print(right)

# 集計
ans = 0
for i in range(n):
    l = left[i]
    r = right[i+1]
    ans = max(ans, gcd(l, r))

print(ans)

Buggy submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
import math
from functools import reduce

def gcd(numbers):
    return reduce(math.gcd, numbers)

n = int(input())
a_l = list(map(int, input().split()))

g_max = 1
for i in range(n):
    d = a_l.pop(0)
    g = gcd(a_l)
    # print(g)
    g_max = max(g, g_max)
    # print(d)
    a_l.append(d)

print(g_max)
Problem p03071 (python)

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

a,b = map(int,input().split() )

sum = 0
for i in range(2):
    if a>=b :
        sum=sum+a
        a=a-1
    else:
        sum=sum+b
        b=b-1

print(sum)

Buggy submission (verdict: Runtime Error):
>|python|
# -*- coding: utf-8 -*-

A,B = map(int,input().split() )

sum = 0
for i in range(2):
    if A >= B :
        sum = sum + A
        A = A - 1
    else:
        sum = sum + B
        B = B - 1

print(sum)
||<
Problem p03408 (python)

Fixed submission:
n=[input() for _ in range(int(input()))]
m=[input() for _ in range(int(input()))]
l=list(set(n))
print(max(0,max(n.count(l[i])-m.count(l[i]) for i in range(len(l)))))

Buggy submission (verdict: Runtime Error):
n=[input() for _ in range(int(input()))]
m=[input() for _ in range(int(input()))]
l=list(set(n))
print(max(0,max(n.count(l[i])-m.count(l[i])) for i in range(len(l))))

Buggy submission (verdict: Runtime Error):
n=[input() for _ in range(int(input()))]
m=[input() for _ in range(int(input()))]
l=list(set(n))
print(max([0,n.count(l[i])-m.count(l[i]) for i in range(len(l))]))

Buggy submission (verdict: Runtime Error):
n=[input() for _ in range(int(input()))]
m=[input() for _ in range(int(input()))]
l=list(set(n))
print(max(0,n.count(l[i])-m.count(l[i]) for i in range(len(l))))
Problem p03777 (python)

Fixed submission:
a,b=input().split()
if a=="H":
  print(b)
elif b=="H":
  print("D")
else:
  print("H")

Buggy submission (verdict: Runtime Error):
a,b=input().split()
if a=="H":
  print(b)
elif b=="H":
  print("D")
elif:
  print("H")
Problem p02717 (python)

Fixed submission:
if __name__ == '__main__':
    a,b,c = input().split(" ")
    a,b = b,a
    a,c = c,a
    print(a, b, c)

Buggy submission (verdict: Runtime Error):
def is_lunlun(i):
    list_i = list(str(i))
    for j in range(len(list_i)-1):
        if int(list_i[j]) == 0:
            if int(list_i[j+1]) not in [1,9,0]:
                return False
        elif int(list_i[j]) == 1:
            if int(list_i[j+1]) not in [0,1,2]:
                return False
        elif int(list_i[j]) == 9:
            if int(list_i[j+1]) not in [8,9]:
                return False
        else:
            if abs(int(list_i[j]) - int(list_i[j+1])) > 1:
                return False
    return True



if __name__ == '__main__':
    k = int(input())
    lunlun = (i for i in range(3234566667) if is_lunlun(i))
    for count, i in enumerate(lunlun):
        if count == k:
            print(i)
            break

Buggy submission (verdict: Runtime Error):
if __name__ == '__main__':
    a,b,c = raw_input().split(" ")
    a,b = b,a
    a,c = c,a
    stdout(a, b, c)
Problem p02718 (python)

Fixed submission:
n,m = list(map(int,input().split()))
votes = [int(x) for x in input().split()]
votesum = sum(votes)
st = votesum / (4 * m)
count = 0
for v in votes :
    if v >= st:
        count += 1
print("Yes" if count >= m else "No")

Buggy submission (verdict: Runtime Error):
n,m = list(map(int,input().split()))
votes = list(map(int,input().split())

s_vote = sum(vote)
st = 1 // 4 * s_vote
count = 0
for v in votes :
    if v >= st:
        count += 1
print("Yes" if count >= m else "No")
Problem p02888 (python)

Fixed submission:
import bisect
n = int(input())
l = list(map(int,input().split()))
l.sort()
ans =0
for i in range(1,n):
    for j in range(i):
        p = l[i]+ l[j]
        q = bisect.bisect_left(l,p)
        ans += q-i-1

print(ans)

Buggy submission (verdict: Runtime Error):
import bisect
N = int(input())
l = list(map(int,input().split()))
l.sort()
ans =0
for i in range(1,n):
    for j in range(i):
        p = l[i]+ l[j]
        q = bisect.bisect_left(l,p)
        ans += q-i-1

print(ans)

Buggy submission (verdict: Runtime Error):
import bisect
N = int(input())
L = list(map(int,input().split()))
L.sort()
ans =0
for i in range(1,n):
    for j in range(i):
        p = l[i]+ l[j]
        q = bisect.bisect_left(l,p)
        ans += q-i-1

print(ans)
Problem p03102 (python)

Fixed submission:
N,M,C=map(int,input().split())
B=list(map(int,input().split()))
count=0
for i in range(N):
 A=list(map(int,input().split()))
 p=C
 for j in range(M):p+=A[j]*B[j]
 if p>0:count+=1
print(count)

Buggy submission (verdict: Runtime Error):
N , M ,C  = map(int,input().split())
B = map(int, input().split())

count = 0
for i in range(N):
    A = list(map(int, input().split()))
    p = C
    for j in range(M):
        p+= A[j]*B[j]
        if p > 0:
            count+=1
print(count)

Buggy submission (verdict: Runtime Error):
N , M ,C  = map(int,input().split())
B = map(int, input().split())

count = 0
for i in range(N):
    A = list(map(int, input().split()))
    p = C
    for j in range(M):
        p+= A[j]*B[j]
        if p > 0:
            count+=1
print(count)
Problem p03206 (python)

Fixed submission:
n = int(input())
if n == 25:
    print("Christmas")
elif n == 24:
    print("Christmas Eve")
elif n == 23:
    print("Christmas Eve Eve")
else:
    print("Christmas Eve Eve Eve")

Buggy submission (verdict: Runtime Error):
N = int(input())
p = [int(input()) for _ in range(N)]

print(sum(p) - int(max(p)/2))
Problem p03281 (python)

Fixed submission:
def count_divisors(n):
    divisors = 0
    for i in range(1, int(n**0.5) +1):
        if n % i == 0:
            divisors += 1
            if i != n // i:
                divisors += 1

    return divisors

n = int(input())

print(sum(count_divisors(x) == 8 for x in range(1, n+1, 2)))

Buggy submission (verdict: Runtime Error):
def count_deivisors(n):
    devisors = 0
    for i in range(1, n**0.5+1):
        if n % i == 0:
            devisors += 1
            if i != n // i:
                devisors += 1

    return devisors

n = int(input())

print(sum(count_deivisors(x) == 8 for x in range(1,n+1,2)))
Problem p03289 (python)

Fixed submission:
import sys

s = input()
if s[0] == "A" and s.count("C") == 1 and "C" in s[2:-1]:
    ss = set(s)
    ss.remove("A")
    ss.remove("C")
    SS = set([i.upper() for i in ss])
    if len(ss & SS) == 0:
        print("AC")
        sys.exit()

print("WA")

Buggy submission (verdict: Runtime Error):
import sys

s = input()
if s[0] == "A" and s.count("C") == 1 and "C" in s[2:-1]:
    ss = set(s)
    ss.remove("A")
    ss.remove("C")
    SS = [i.upper() for i in ss]
    if len(ss & SS) == 0:
        print("AC")
        sys.exit()

print("WA")
Problem p03338 (python)

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

m = 0
for i in range(1, n - 1):
  a = s[:i]
  b = s[i:]
  c = len(set(a) & set(b))
  if c >= m:
    m = c

print(m)

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

    m = 0
    for i in range(1, n - 1):
        a = s[:i]
        b = s[i:]
        c = len(set(a) & set(b))
        if c >= m:
            m = c

    print(m)
Problem p03407 (python)

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

print('Yes' if a+b >= c else 'No')

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

pirnt('Yes' if a+b >= c else 'No')
Problem p03624 (python)

Fixed submission:
S = list(input())
alpha_list = [chr(i) for i in range(97,97+26)]

S = set(S)
alpha_list = set(alpha_list)
answer = alpha_list - S
if alpha_list == S:
    print('None')
else:
    print(sorted(list(answer))[0])

Buggy submission (verdict: Runtime Error):
S = list(input())
alpha_list = [chr(i) for i in range(97,97+26)]

S = set(S)
alpha_list = set(alpha_list)
answer = alpha_list - S
answer = sorted(list(answer))[0]
print(answer)
Problem p03738 (python)

Fixed submission:
A = int(input())
B = int(input())

print('GREATER' if A>B else 'LESS' if B>A else 'EQUAL' )

Buggy submission (verdict: Runtime Error):
A = int(input())
B = int(input())

print('GREATER' if A>B else 'LESS' if b>a else 'EQUAL' )
Problem p03777 (python)

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

print("H" if a ==b else "D" )

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

if a == 'H':
    print(b)
elif a == 'D' and b =='H'
    print('D')
else:
    print('H')
Problem p04030 (python)

Fixed submission:
s = input()
m = []
for i in s:
    if i == "0":
        m.append(i)
    elif i == "1":
        m.append(i)
    else:
        try:
            m.pop(-1)
        except:
            continue
answer = "".join(m)
print(answer)

Buggy submission (verdict: Runtime Error):
s = input()
m = []
for i in s:
    if i == "0":
        m.append(i)
    elif i == "1":
        m.append(i)
    else:
        m.pop(-1)
answer = "".join(m)
print(answer)

Buggy submission (verdict: Runtime Error):
s = input()
answer = []
for i in s:
    if i == "0":
        answer.append(0)
    elif i == "1":
        answer.append(1)
    else:
        answer.pop(-1)
print(*answer)
Problem p02999 (python)

Fixed submission:
X,A = map(int,input().split())

if X < A:
    print('0')
else:
    print('10')

Buggy submission (verdict: Runtime Error):
X,A = input()

if X < A:
    print('0')
else:
    print('10')

Buggy submission (verdict: Runtime Error):
X = input()
A = input()

if X < A:
    print('0')
else:
    print('10')

Buggy submission (verdict: Runtime Error):
X = input()
A = input()

if X < A:
    print('0')
else:
    print('1')
Problem p02717 (python)

Fixed submission:
a,b,c=input().split()
 
print(str(c)+" "+str(a)+" " + str(b) + " ")

Buggy submission (verdict: Runtime Error):
a,b,c=(int(x) for x in input().split())
 
print(str(c)+" "+str(a)+" " + str(b) " ")

Buggy submission (verdict: Runtime Error):
a,b,c=input().split()
 
print(str(c)+" "+str(a)+" " + str(b) " ")

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

print(c+" "+a+" " + b " ")

Buggy submission (verdict: Runtime Error):
x = input()
y = input()
z = input()
  
print(z + " " + x + " " + y)
Problem p02741 (python)

Fixed submission:
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]

index = input()
index = int(index)
print(list[index-1])

Buggy submission (verdict: Runtime Error):
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]

index = input()
print(list[index])

Buggy submission (verdict: Runtime Error):
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]

index = input()
print(list[index-1: index-1])

Buggy submission (verdict: Runtime Error):
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]

index = input()
print(list[index])

Buggy submission (verdict: Runtime Error):
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]

index = input()
print(list[index-1])

Buggy submission (verdict: Runtime Error):
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]

index = input()
print(list[index+1])