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

Fixed submission:
S = input()
if int(S[:2]) > 12:
    if 13 > int(S[2:]) > 0:
        print("YYMM")
    else:
        print("NA")
elif 0 < int(S[:2]) < 13:#12xx~01xx
    if int(S[2:]) > 12:
        print("MMYY")
    elif 0 < int(S[2:]) < 13:
        print("AMBIGUOUS")
    else:
        print("MMYY")
else:#00xx
    if 0 < int(S[2:]) <13:
        print("YYMM")
    else:
        print("NA")

Buggy submission (verdict: Runtime Error):
S = int(input())
if S[:2] > 12:
    if 13 > S[2:] > 0
        print("YYMM")
    else:
        print("NA")
elif 0 < S[:2] < 13:#12xx~01xx
    if S[2:] > 12:
        print("MMYY")
    elif 0 < S[2:] < 13:
        print("AMBIGUOUS")
    else:
        print("YYMM")
else:#00xx
    if 0 < S[2:] <13:
        print("YYMM")
    else:
        print("NA")
Problem p03075 (python)

Fixed submission:
a = []
for _ in range(5):
    a.append(int(input()))
k = int(input())
for i in range(5):
    for j in a[i+1:]:
        if abs(a[i]-j) > k:
            print(":(")
            exit()
print("Yay!")

Buggy submission (verdict: Runtime Error):
for _ in range(6):
    a.append(int(input()))
for i in range(6):
    for j in a[i+1:]:
        if abs(a[i]-j) > k:
            print(":(")
            exit()
print("Yay!")
Problem p02771 (python)

Fixed submission:
def resolve():
    s = set(map(int,input().split()))
    if len(s) == 2:
        print("Yes")
    else:
        print("No")
resolve()

Buggy submission (verdict: Runtime Error):
a = list(map(int,ipnut().split()))
a = set(a)
if len(a)==2:
  print("Yes")
else:
  print("No")
Problem p02773 (python)

Fixed submission:
def resolve():
    import collections
    n = int(input())
    c = list(collections.Counter([input() for _ in range(n)]).most_common())
    s = []
    m = c[0][1]
    for i in c:
        if i[1] !=m:
            break
        s.append(i[0])
    s.sort()
    print("\n".join(s))
resolve()

Buggy submission (verdict: Runtime Error):
def resolve():
    import collections
    n = int(input())
    c = list(collections.Counter([int(input()) for _ in range(n)]).most_common())
    s = []
    m = c[0][0]
    for i in c:
        if c !=m:
            break
        s.append(i[0])
    s.sort()
    print("\n".join(s))
resolve()
Problem p02790 (python)

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

Buggy submission (verdict: Runtime Error):
a,b=map(int,ipnut().split())
print(str(min(int(a),int(b)))*max(int(a),int(b)))
Problem p02847 (python)

Fixed submission:
s = input()
if s=="SUN":
  print(7)
elif s=="MON":
  print(6)
elif s=="TUE":
  print(5)
elif s=="WED":
  print(4)
elif s=="THU":
  print(3)
elif s=="FRI":
  print(2)
elif s=="SAT":
  print(1)

Buggy submission (verdict: Runtime Error):
rot = int(input())
s = input()
g = (chr((ord(c) - ord('A') + rot) % 26 + ord('A')) for c in s)
print(g)

Buggy submission (verdict: Runtime Error):
s = input()
if s=="SUN":
  print(7)
elif s=="MON":
  print(6)
elif s=="TUE":
  print(5)
else s=="WED":
  print(4)
else s=="THU":
  print(3)
else s=="FRI":
  print(2)
else s=="SAT":
  print(1)
Problem p02897 (python)

Fixed submission:
import math
n=int(input())
print(math.ceil(n/2)/n)

Buggy submission (verdict: Runtime Error):
import math
n=input()
print(math.ceil(n/2)/n)
Problem p02987 (python)

Fixed submission:
s = ''.join(sorted(input()))
if(s[0]==s[1] and s[2] == s[3] and s[1] != s[3]):
  print("Yes")
else:
  print("No")

Buggy submission (verdict: Runtime Error):
s=input()
asdf=True
deta=tuple(s)
if len(data)==2:
  print("No")
else:
  if s.count(data[0])==2:
    print("Yes")
  else:
    print("No")

Buggy submission (verdict: Runtime Error):
n=int(input())
p=list(map(int,input().split()))
uuum = 0
for i in range(n-2):
  aaa = [p[i],p[i+1],p[i+2]]
  aaa.sort()
  if aaa[1]==p[i+1]:
    uuum+=1
print(uuum)

Buggy submission (verdict: Runtime Error):
s=input()
s.sort()
if s[0]==s[1]and s[2]==s[3]:
  print("Yes")
else:
  print("No")
Problem p03011 (python)

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

Buggy submission (verdict: Runtime Error):
a = list(map(int,input().split()))
a.sort()
print(sum(a[0:1])
Problem p03041 (python)

Fixed submission:
a,b = map(int,input().split())
txt = list(input())
txt[b - 1] = txt[b - 1].lower()
print("".join(txt))

Buggy submission (verdict: Runtime Error):
a,b = map(int,input().split())
txt = input()
txt[b] = txt[b].lower()
print(txt)

Buggy submission (verdict: Runtime Error):
a,b = map(int,input().split())
txt = input()
txt[b] = txt[b].lower
print(txt)
Problem p03075 (python)

Fixed submission:
a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())
if (e-a)> k:
  print(":(")
else:
  print("Yay!")

Buggy submission (verdict: Runtime Error):
a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())
s = [a,b,c,d,e]
kk = "Yay!"
for z in range(lan(s)):
  ss = s[(z+1):]
  for y in ss:
    if s[z] - y > k :
      kk=":("
      
print(kk)

Buggy submission (verdict: Runtime Error):
a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())
inp=[a,b,c,d,e]
i=0;
j=0;
kek=true
while i<5:
  j=i
  while j<5:
    if inp[j]-inp[i]>k:
      kek=false
      
if kek:
  print "Yay!"
else:
    print ":("

Buggy submission (verdict: Runtime Error):
a=input()
b=input()
c=input()
d=input()
e=input()
k=input()
inp=[a,b,c,d,e]
i=0;
j=0;
kek=true
while i<5:
  j=i
  while j<5:
    if inp[j]-inp[i]>k:
      kek=false
      
if kek:
  print "Yay!"
else:
    print ":("

Buggy submission (verdict: Runtime Error):
a=input()
b=input()
c=input()
d=input()
e=input()
k=input()
inp=[a,b,c,d,e]
i=0;
j=0;
kek=true
while i<5:
  j=i
  while j<5:
    if inp[j]-inp[i]>k:
      kek=false
      
print "Yay!" if kek else print ":("

Buggy submission (verdict: Runtime Error):
a=input()
b=input()
c=input()
d=input()
e=input()
k=input()
inp=[a,b,c,d,e]
i=0;
j=0;
kek=true
while i<5:
  j=i
  while j<5:
    if inp[j]-inp[i]>k:
      kek=false
      
print("Yay!") if kek else print(":(")

Buggy submission (verdict: Runtime Error):
a=input()
b=input()
c=input()
d=input()
e=input()
k=input()
inp=[a,b,c,d,e]
i=0;
j=0;
kek=true
while i<5:
  j=i
  while j<5:
    if inp[j]-inp[i]>k:
      kek=false
      
print("Yay!") if kek else print(":(")
Problem p03242 (python)

Fixed submission:
a = {"1":"9","9":"1"}
z = input()
m = ""
for i in z:
  m += a[i]

print(m)

Buggy submission (verdict: Runtime Error):
a={"1":"9","9":"1"}
t=input()
n=""
for i is range(3):
  n+=a[t[i]]
print(n)

Buggy submission (verdict: Runtime Error):
a = {"1":9,"9":1}
z = input()
m = ""
for i in z:
  m += a[i]

print(m)
Problem p03315 (python)

Fixed submission:
n = {"++++":4,"+++-":2,"++--":0,"+---":-2,"----":-4}
s = "".join(sorted(input()))
print(n[s])

Buggy submission (verdict: Runtime Error):
n = 0
s = input()
for ss in s:
  if ss="+":
    n = n+1
  else:
    n = n-1
print(n)

Buggy submission (verdict: Runtime Error):
a=input()
z=0
for i in range(4):
   z-=1 if a[i]=='-'else z+=1
Problem p03327 (python)

Fixed submission:
a=int(input())
if a<1000:
  print("ABC")
else:
  print("ABD")

Buggy submission (verdict: Runtime Error):
print("ABC" if input()<1000 else "ABD")
Problem p03834 (python)

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

Buggy submission (verdict: Runtime Error):
s = Input()
r1 = s[0:4]
r2 = s[6:12]
r3 = s[14:]
print("{} {} {}".format(r1, r2, r3))
Problem p02624 (python)

Fixed submission:
n = int(input())
ans = 0
for _ in range(1, n+1):
    y = n // _
    ans += y * (y + 1) / 2 * _  
print(int(ans))

Buggy submission (verdict: Runtime Error):
n = int(input())
ans = 0
for _ in range(1, n+1):
    y = n // _
    ans += y * (y + 1) / 2 * _  
    print(int(ans))
Problem p02627 (python)

Fixed submission:
n = str(input())
if n.islower():
    print('a')
else:
    print('A')

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

x = n 
nums = []
ans = ''
for i in range(1, 11):
    if 26**i >= n:
        for _ in range(i):
            print(x, x%26)
            x -= 1
            l = x % 26
            x //=  26
            nums.append(l)
        break
    else:
        n -= 26**i
        
for _ in nums:
    ans +=(chr(ord('a') + _))
    
print(ans[::-1])
Problem p02629 (python)

Fixed submission:
n = int(input())

x = n 
nums = []
ans = ''
for i in range(1, 12):
    if 26**i >= n:
        for _ in range(i):
            x -= 1
            l = x % 26
            x //=  26
            nums.append(l)
        break
    else:
        n -= 26**i
        
for _ in nums:
    ans +=(chr(ord('a') + _))
    
print(ans[::-1])

Buggy submission (verdict: Runtime Error):
x = n 
nums = []
ans = ''
for i in range(1, 12):
    if 26**i >= n:
        for _ in range(i):
            print(x, x%26)
            x -= 1
            l = x % 26
            x //=  26
            nums.append(l)
        break
    else:
        n -= 26**i
        
for _ in nums:
    ans +=(chr(ord('a') + _))
    
print(ans[::-1])
Problem p02729 (python)

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

ans = n * (n - 1) // 2 + m * (m - 1) // 2

print(ans)

Buggy submission (verdict: Runtime Error):
L = float(input())

ans = float((L/3)**3)

print(ans)
Problem p02759 (python)

Fixed submission:
n = int(input())

if n % 2 == 1:
    ans = n//2 + 1
else:
    ans = n//2
print(ans)

Buggy submission (verdict: Runtime Error):
n, m = map(int, input().split())
lst = [[] for _ in range(n)]
for _ in range(m):
    s, c = map(int, input().split())
    nums = append([s-1,c])

print(nums)
Problem p02833 (python)

Fixed submission:
import math
n = int(input())

def fact(n, x, ans):
    if x > n:
        return ans
    else:
        ans +=  math.floor(n//(2*x))
        return fact(n, x*5, ans)

if n%2:
    print(0)
else:
    print(fact(n, 5, 0))

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

def fact(n, x, ans):
    if x > n:
        return ans
    else:
        ans += math.floor(n/(2*x))
        return fact(n, x*5, ans)

if n < 2:
    print(1)
elif n%2:
    print(0)
else:
    print(fact5(n, 5, 0))

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

def fact(n, x, ans):
    if x > n:
        return ans
    else:
        ans += math.floor(n/(2*x))
        return fact(n, x*5, ans)

if n < 2:
    print(1)
elif n%2:
    print(0)
else:
    print(fact5(n, 5, 0))
Problem p02835 (python)

Fixed submission:
a, b, c = map(int, input().split())
if a+b+c >= 22:
    print('bust')
else:
    print('win')

Buggy submission (verdict: Runtime Error):
n = int(input())
lst = [[-1 for _ in range(n)] for _ in range(n)]
for _ in range(n):
    c = int(input())
    for c1 in range(c):
        x, y = map(int, input().split())
        x -= 1
        lst[_][x] = y
        
ans = 0
for bit in range(2**n):
    flg = True
    for a in range(n):
        if (bit >> a) & 1:
            for x in range(n):
                if lst[a][x] != -1 and ((bit >> x) & 1) != lst[a][x]:
                  flg = False
                  break
    if flg:
        ans = max(ans, bin(bit).count('1'))
print(ans)

Buggy submission (verdict: Runtime Error):
n = int(input())
lst = [[-1 for _ in range(n)] for _ in range(n)]
for _ in range(n):
    c = int(input())
    for c1 in range(c):
        x, y = map(int, input().split())
        x -= 1
        lst[_][x] = y
        
ans = 0
for bit in range(2**n):
    flg = True
    for a in range(n):
        if (bit >> a) & 1:
            for x in range(n):
                if lst[a][x] != -1 and ((bit >> x) & 1) != lst[a][x]:
                	flg = False
                    break
    if flg:
        ans = max(ans, bin(bit).count('1'))
print(ans)

Buggy submission (verdict: Runtime Error):
n = int(input())
lst = [[-1 for _ in range(n)] for _ in range(n)]
for _ in range(n):
    c = int(input())
    for c1 in range(c):
        x, y = map(int, input().split())
        x -= 1
        lst[_][x] = y

ans = 0
for bit in range(n**2 - 1):
    flg = True
    for a in range(n):
        if (bit >> a) & 1:
            for x in range(n):
                if lst[a][x] != -1 and ((bit >> x) & 1) != lst[a][x]:
                    flg = False
                    break
if flg:
  ans = max(ans, bin(bit).count('1'))
print(ans)
Problem p02951 (python)

Fixed submission:
from sys import stdin
a, b, c = [int(x) for x in stdin.readline().rstrip().split()]

l = c - (a - b)

if l < 0:
  print(0)
else:
  print(l)

Buggy submission (verdict: Runtime Error):
n = int(input())
l = list(map(int, input().split())) 
l2 =[]
i = len(l)
for i in range(len(l):
  if l[i] > l[i-1]:
    l[i] += 1
    i += 1

i = 0
l2 = [l[i] <= l[i+1] for i in range(len(l)-1)]

if all(l2):
  print("Yes")
else:
  print("No")
Problem p03295 (python)

Fixed submission:
#区間スケジューリング
n, m = map(int, input().split())
lst = []
for _ in range(m):
    a, b = map(int, input().split())
    lst.append([a, b])

lst.sort(key=lambda x:x[1])

ans = 0
ed = 0
for _ in lst:
    if _[0] < ed:
      pass
    else:
        ed = _[1]
        ans += 1
print(ans)

Buggy submission (verdict: Runtime Error):
#区間スケジューリング
n, m = map(int, input().split())
lst = []
for _ in range(m):
    a, b = map(int, input().split())
    lst.append([a, b])

lst.sort(key=lambda x:x[1])

ans = 0
ed = 0
for _ in lst:
    if _[0] < ed:
    else:
        ed = _[1]
        ans += 1
print(ans)
Problem p02785 (python)

Fixed submission:
n, k = map(int, input().split())
h = list(map(int, input().split()))
if n <= k:
  print(0)
elif k == 0:
  print(sum(h))
else:
  h = sorted(h)
  print(sum(h[:n-k]))

Buggy submission (verdict: Runtime Error):
n, k = map(int, input().split())
h = list(map(int, input().split()))
if n <= k:
  print(0)
elif k == 0:
  print(sum(h))
else:
  h = sorted(list(map(int, input().split())))
  print(sum(h[:n-k]))

Buggy submission (verdict: Runtime Error):
n, k = map(int, input().split())
if n <= k:
  print(0)
elif k == 0:
  print(sum(h))
else:
  h = sorted(list(map(int, input().split())))
  print(sum(h[:n-k]))

Buggy submission (verdict: Runtime Error):
n, k = map(int, input().split())
if n <= k:
  print(0)
else:
  h = list(map(int, input().split())).sort()
  print(sum(h[:-k]))

Buggy submission (verdict: Runtime Error):
n, k = map(int, input().split())
if n <= k:
  print(0)
  return
h = list(map(int, input().split())).sort()
print(sum(h[:-k]))

Buggy submission (verdict: Runtime Error):
n, k = map(int, input().split())
if n <= k:
  print(0)
  exit()
h = list(map(int, input().split())).sort()
print(sum(h[:-k]))
Problem p02990 (python)

Fixed submission:
import math


def c_cnt(n, r):
    if n - r < 0:
        return 0
    return math.factorial(n) // (math.factorial(n - r) * (math.factorial(r)))


N, K = map(int, input().split())
red = N - K
div = 1
for i in range(1,K+1):
    place = c_cnt(red+1, i)
    if 1 < i < K:
        div = c_cnt(K-1, i-1)
    else:
        div = 1
    print(place * div % (10**9+7))

Buggy submission (verdict: Runtime Error):
import math
 
 
def c_cnt(n, r):
    return math.factorial(n) // (math.factorial(n - r) * (math.factorial(r)))
 
 
N, K = map(int, input().split())
red = N - K
div = 1
for i in range(1,K+1):
    place = c_cnt(red+1, i)
    if 1 < i < K:
        div = c_cnt(K-1, i-1)
    else:
        div = 1
    print((place * div) % (10**9+7))

Buggy submission (verdict: Runtime Error):
import math


def c_cnt(n, r):
    return math.factorial(n) // (math.factorial(n - r) * (math.factorial(r)))


N, K = map(int, input().split())
red = N - K
div = 1
for i in range(1,K+1):
    place = c_cnt(red+1, i)
    if 1 < i < K:
        div = c_cnt(K-1, i-1)
    else:
        div = 1
    print(place * div % (10**9+7))

Buggy submission (verdict: Runtime Error):
import math


def c_cnt(n, r):
    return math.factorial(n) // (math.factorial(n - r) * (math.factorial(r)))


def d_cnt(k, n):
    return (math.factorial(k) // (math.factorial(k - n) * (math.factorial(n))))


N, K = map(int, input().split())
red = N - K
div = 1
for i in range(1,K+1):
    place = c_cnt(red+1, i)
    if 1 < i:
        div = c_cnt(K-1, i-1)
    print(place * div % (10**9+7))
Problem p03041 (python)

Fixed submission:
N, K = map(int, input().split())
S = list(input())
S[K-1] = S[K-1].lower()
print(''.join(S))

Buggy submission (verdict: Runtime Error):
import math
from functools import reduce

N, K = map(int, input().split())
p = 0
dnms = []


def calc_p(n, c):
    return 1/n * pow(1/2, c)


def calc_dnm(n, c):
    return n * 2 ** c


def calc_lcm(ns):
    return reduce(lcm, ns, 1)


def lcm(x, y):
    return (x * y) // math.gcd(x, y)


for i in range(1, N+1):
    score = i
    cnt = 0
    while score <= K:
        score *= 2
        cnt += 1
    dnms.append(calc_dnm(N, cnt))
    p += calc_p(N, cnt)

print(p)

l = calc_lcm(dnms)
mlcls = [l/x for x in dnms]
print(sum(mlcls) / calc_lcm(dnms))
Problem p02699 (python)

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

Buggy submission (verdict: Runtime Error):
n = str(input())
count = 0
for j in range(len(n) - 4):
  for i in range(len(n) - 3 - j):
    if(int(n[i:4 + i + j]) % 2019 == 0):
       count += 1

print(count)
Problem p02723 (python)

Fixed submission:
def main():
  x = input()
  if(len(x) == 6 and x.islower()):
    if(x[2] == x[3] and x[4] == x[5]):
        print("Yes")
    else:
      print("No")
    
if __name__ == "__main__":
  main()

Buggy submission (verdict: Runtime Error):
def main():
  k, N = (int(x) for x in input().split())
  min_LIST = []
  LIST = []
  LIST = list(map(int,input().split()))

  for i in range(len(LIST) - 1):
    min_LIST.append(LIST[i + 1] - LIST[i])
    if(min_LIST[i] <= (LIST[i + 1] - LIST[i])):
      x = (LIST[i + 1] - LIST[i])

  min_LIST.append(LIST[0] + (k - LIST[-1]))
  if(x <= (LIST[0] + (k - LIST[-1]))):
    x = (LIST[0] + (k - LIST[-1]))

  sum_list = sum(min_LIST) - x

  print(sum_list)
if __name__ == "__main__":
  main()
Problem p02725 (python)

Fixed submission:
def main():
  k, N = (int(x) for x in input().split())
  min_LIST = []
  LIST = []
  LIST = list(map(int,input().split()))
  x = 0

  for i in range(len(LIST) - 1):
    min_LIST.append(LIST[i + 1] - LIST[i])
    if(x <= min_LIST[i]):
      x = min_LIST[i]

  if(N != 2):
    min_LIST.append(LIST[0] + (k - LIST[-1]))
    if(x <= (LIST[0] + (k - LIST[-1]))):
      x = (LIST[0] + (k - LIST[-1]))

  sum_list = sum(min_LIST) - x

  print(sum_list)
if __name__ == "__main__":
  main()

Buggy submission (verdict: Runtime Error):
def main():
  k, N = (int(x) for in input().split())
  LIST = []
  min_LIST = []
  for i in range(N):
    l.append(int(input()))

  for i in range(len(LIST) - 1):
    min_LIST.append(LIST[i + 1] - LIST[i])
    if(min_LIST <= (LIST[i + 1] - LIST[i])):
      x = (LIST[i + 1] - LIST[i])

  if(min_LIST <= (LIST[0] + (k - LIST[-1])):
    x = (LIST[0] + (k - LIST-1]))

  sum_list = sum(min_LIST) - x

  print(sum_list)
if __name__ == "__main__":
  main()
Problem p02754 (python)

Fixed submission:
import math

def main():
  n,a,b = (int(x) for x in input().split())

  num_a = (math.floor(n/(a + b)))
  num_b = int(n % (a + b))

  print(int(num_a * a + min(a, num_b)))
  
if __name__ == '__main__':
  main()

Buggy submission (verdict: Runtime Error):
def main():
  n,a,b = (int(x) for x in input().split())

  num_a = int(n / (a + b))
  num_b = int(n % (a + b))
  
  if(num_b >= a):
    nun_x = a
  else:
    num_x = num_b

  print(num_a * a + num_x)
  
if __name__ == '__main__':
  main()
Problem p02773 (python)

Fixed submission:
from collections import Counter
n = int(input())
word = Counter([input() for i in range(n)]).most_common()
print('\n'.join(sorted([num[0] for num in word if int(num[1]) == word[0][1]])))

Buggy submission (verdict: Runtime Error):
n = int(input())
word = [input() for i in range(n)]
test = list([x,0] for x in set(word))

for i, num in enumerate(test):
  test[i][1] = word.count(num[0])

num_max = int(max(test, key=lambda x: x[1])[1])

print('\n'.join(sorted([num[0] for num in test if(int(num[1] == num_max)))))
Problem p02831 (python)

Fixed submission:
import fractions

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

print(a * b // fractions.gcd(a, b))

Buggy submission (verdict: Runtime Error):
import fractions

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

print(int(a * b / fractions.gcd(a * b)))

Buggy submission (verdict: Runtime Error):
import fractions

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

print(a * b / fracions.gcd(a * b))

Buggy submission (verdict: Runtime Error):
import fractions

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

print(a * b / fracions.gcd(a * b))
Problem p02951 (python)

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

Buggy submission (verdict: Runtime Error):
a, b, c = map(int, input().split())
if(c // (a - b) != 0):
  print(c % (a - b))
else:
  print(0)

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

Fixed submission:
import math
t = list((input()))
sum=0
for e in t:
    sum+=int(e)
if sum%9==0:
    print('Yes')
else:
    print('No')

Buggy submission (verdict: Runtime Error):
import math
t = int(input())
sum =0
while t>0:
    sum += t%10
    t = int(t/10)

if sum%9==0:
    print('Yes')
else:
    print('No')
Problem p02951 (python)

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

A = list(map(int,input().split()))
remain = 0

if A[2] - (A[0] - A[1]) <= 0:
	print(remain)
else:
	remain = A[2] - (A[0] - A[1])
	print(remain)

Buggy submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
N = int(input())
H = list(map(int,input().split()))

ans = 'Yes'
diff = 0

for i in range(N - 1):
	diff = H[i + 1] - H[i]

	if diff > 1:
		H[i + 1] -= 1
	elif diff < 0:
		ans = 'No'
print(ans)
Problem p02594 (python)

Fixed submission:
X = int(input())

if (X >= 30):
    print("Yes")
else:
    print("No")

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

if (N >= 30):
    print("Yes")
else:
    print("No")
Problem p02571 (python)

Fixed submission:
S = input()
T = input()
 
def match_num_character(x, y):
  count = 0
  for a, b in zip(x, y):
    if a == b:
      count += 1
      
  return count
 
length = len(T)
max_count = max([match_num_character(S[i:i+length], T) for i in range(1+len(S) - length)])
 
print(length - max_count)

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

def match_num_character(x, y):
  count = 0
  for a, b in zip(x, y):
    if a == b:
      count += 1
      
  return count

length = len(T)
max_count = max([match_num_character(S[i:i+length], T) for i in range(len(S) - length)])

print(length - max_count)
Problem p02771 (python)

Fixed submission:
x,y,z=(input().split(" "))
if z == y:
  if y ==x:
    print("No")
  else:
    print("Yes")
else:
  if z ==x:
    print("Yes")
  else:
    if y == x:
      print("Yes")
    else:
      
      print("No")

Buggy submission (verdict: Runtime Error):
x,y,z=(input().split(" "))
if z == y:
  if y ==x:
    return("No")
  else:
    return("Yes")
else:
  if z ==x:
    return("Yes")
  else:
    if y == x:
      return("Yes")
    else:
      return("No")

Buggy submission (verdict: Runtime Error):
x,y,z=(input().split(" "))
if z == y:
  if y == x:
    return "No"
  else:
    return "Yes"
else:
  if z == x:
    return "Yes"
  else:
    if y == x:
      return "Yes"
    else:
      return "No"

Buggy submission (verdict: Runtime Error):
x,y,z=(input().split(" "))
if z == y:
  if y ==x:
    return "No"
  else:
    return "Yes"
else:
  if z ==x:
    return "Yes"
  else:
    if y == x:
      return "Yes"
    else:
      return "No"

Buggy submission (verdict: Runtime Error):
z,y,x=(int(x) for x in input().split())
if z == y:
  if y ==x:
    return "No"
  else:
    return "Yes"
else:
  if z ==x:
    return "Yes"
  else:
    if y == x:
      return "Yes"
    else:
      return "No"

Buggy submission (verdict: Runtime Error):
z,y,x=(int(x) for x in input().split())
if z == y:
  if y ==x:
    return "No"
  else:
    return "Yes"
else:
  if z ==x:
    return "Yes"
  else:
    if y == x:
      return "Yes"
    else:
      return "No"
Problem p02859 (python)

Fixed submission:
a = int(input())
a *= a
print(a)

Buggy submission (verdict: Runtime Error):
a = input("半径")
print(a*a)