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

Fixed submission:
n = int(input())
h = list(map(int, input().split()))
cnt = 0
ans = 0
for i in range(n-1):
   if h[i] >= h[i+1]:
      cnt += 1
      ans = max(ans, cnt)
   else:
      cnt = 0
print(ans)

Buggy submission (verdict: Runtime Error):
n = int(input())
h = list(map(int, input().split()))
cnt = 0
move_cnt = []
for i in range(n-1):
   if h[i] >= h[i+1]:
      cnt += 1
      move_cnt.append(cnt)
   else:
      cnt = 0
      move_cnt.append(cnt) 
print(max(move_cnt))

Buggy submission (verdict: Runtime Error):
n = int(input())
h = list(map(int, input().split()))
cnt = 0
move_cnt = []
for i in range(n-1):
   if h[i] >= h[i+1]:
      cnt += 1
      move_cnt.append(cnt)
   else:
      move_cnt.append(cnt) 
      cnt = 0
      
print(max(move_cnt))

Buggy submission (verdict: Runtime Error):
n = int(input())
h = list(map(int, input().split()))
cnt = 0
ans = 0
for i in range(n-1):
   if h[i] >= h[i+1]:
      cnt += 1
      move_cnt.append(cnt)
   else:
      move_cnt.append(cnt) 
      cnt = 0
      
print(max(move_cnt))

Buggy submission (verdict: Runtime Error):
n = int(input())
h = list(map(int, input().split()))
cnt = 0
ans = 0
for i in range(n-1):
   if h[i] >= h[i+1]:
      cnt += 1
      move_cnt.append(cnt)
   else:
      cnt = 0
      move_cnt.append(cnt)
print(max(move_cnt))

Buggy submission (verdict: Runtime Error):
n = int(input())
h = list(map(int, input().split()))
cnt = 0
move_cnt = []
for i in range(n-1):
   if h[i] >= h[i+1]:
      cnt += 1
      move_cnt.append(cnt)
   else:
      cnt = 0
print(max(move_cnt))

Buggy submission (verdict: Runtime Error):
n = int(input())
h = list(map(int, input().split()))
cnt = 0
move_cnt = []
for i in range(n-1):
   if h[i] >= h[i+1]:
      cnt += 1
   else:
      move_cnt.append(cnt)
      cnt = 0
print(max(move_cnt))
Problem p02934 (python)

Fixed submission:
n = int(input())
a = map(int, input().split())
print(1/sum(1/i for i in a))

Buggy submission (verdict: Runtime Error):
n = int(input())
a = [int(input()) for i in range(n)]
cnt = 0
for k in range(n):
    cnt += 1/a[k]
print(1/cnt)
Problem p02983 (python)

Fixed submission:
l, r = map(int,input().split())

ans = 2019
for i in range(l, r):
    for j in range(i+1, r+1):
        tmp = i*j % 2019
        if ans > tmp:
            ans = tmp
        if ans == 0:
            print(ans)
            exit(0)
print(ans)

Buggy submission (verdict: Runtime Error):
l, r = map(int, input().split())
ans = 2019
for i in range(l, r):
   for i in range(l+1, r+1):
      tmp = i*j % 2019
      if ans > tmp:
         ans = tmp         
      if ans == 0:
         print(ans)
         exit(0)
print(ans)

Buggy submission (verdict: Runtime Error):
l, r = map(int, input().split())
num = list(range(l, r+1))
num_map = list(map(lambda j: j % 2019, num)) 
num_map.sort()
print(num_map[0]*num_map[1])
Problem p03076 (python)

Fixed submission:
ae = [int(input()) for _ in range(5)]

sum_ae = 0
g = 9
cnt = 0  
for i in ae:
    if i % 10 != 0:
        g = min(g, i % 10)
        sum_ae += (i//10 + 1) * 10
        cnt += 1
    else:
        sum_ae += i
if cnt != 0:
    print(sum_ae - (10-g))
else:
    print(sum_ae)

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

nxt_time = [0]*n
for i in range(n):
    if ae[i] % 10 == 0:
        nxt_time[i] = ae[i]
    else:
        nxt_time[i] = ae[i] - ae[i] % 10 + 10
    # nxt_time[i] = (ae[i]+9) // 10 * 10
best_time = 99999999
for i in range(n):
    sumtime = 0
    for j in range(n):
        if i == j:
            sumtime += ae[i]
        else:
            sumtime += nxt_time[i]
    
    best_time = min(best_time, sumtime)

print(best_time)
Problem p03085 (python)

Fixed submission:
b = input()
if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'G':
    print('C')
else:
    print('G')

Buggy submission (verdict: Runtime Error):
b = input()
for i in range(len(b)):
  if b[i] == 'A':
    b[i] = 'T'
  elif b[i] == 'T':
    b[i] = 'A'
  elif b[i] == 'G':
    b[i] = 'C'
  else:
    b[i] = 'G'
print(b)
Problem p03284 (python)

Fixed submission:
n, i = map(int, input().split())
if n%i == 0:
    print(0)
else:
    print(1)

Buggy submission (verdict: Runtime Error):
n, i = map(int, input().split())
if n%k == 0:
    print(0)
else:
    print(1)
Problem p03323 (python)

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

if n > 8 or m > 8:
  print(':(')
else:
  print('Yay!')

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

if n > 8 or m > 8:
  print(':(')
else:
  print('Yay!')
Problem p03337 (python)

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

print(max(a+b, a-b, a*b))

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

print(max(a+b, a-b, a*b))
Problem p03361 (python)

Fixed submission:
h, w = map(int, input().split())
s = ['.'*(w+2)]
for i in range(h):
  ss = '.' + input() + '.'
  s.append(ss)
s.append('.'*(w+2))
dx = [1,0,-1,0]
dy = [0,1,0,-1]
for i in range(h):
  for j in range(w):
    cnt = 0
    for k in range(4):
      yi = i + dy[k]
      xi = j + dx[k]
      if s[i][j] == '#' and s[yi][xi] == '.':
        cnt += 1
    if cnt == 4:
      print('No')
      exit()

print('Yes')

Buggy submission (verdict: Runtime Error):
h, w = map(int, input().split())
s = ['.'*(h+2)]
for i in range(h):
  ss = '.' + input() + '.'
  s.append(ss)
s.append('.'*(h+2))
dx = [1,0,-1,0]
dy = [0,1,0,-1]
for i in range(h):
  for j in range(w):
    cnt = 0
    for k in range(4):
      xi = i + dx[k]
      yi = j + dy[k]
      if s[i][j] == '#' and s[xi][yi] == '.':
        cnt += 1
    if cnt == 4:
      print('No')
      exit()

print('Yes')
Problem p03362 (python)

Fixed submission:
n = int(input())
prime5 = []
for i in range(1,5600):
  a = i * 10 + 1
  flag = True
  for j in range(3,int(a**0.5) + 1):
    if a % j == 0:
      flag = False
  if flag: prime5.append(a)
print(*prime5[:n])

Buggy submission (verdict: Runtime Error):
n = int(input())
prime5 = []
for i in range(1,5600):
  a = i * 10 + 1
  # flag = True
  for j in range(3,int(a**0.5) + 1):
    if a % j == 0:
      # flag = False
  else: prime5.append(a)
print(*prime5[:n])
Problem p03377 (python)

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

if 0 <= x-a <= b:
  print('YES')
else:
  print('NO')

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

if 0 <= (x-a) <= b:
  print('Yes')
else:
  print('No')

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

if a > x:
  print('No')
else:
  if a + b < x:
    print('No')
  else:
    if x-a > b:
      print('No')
    else:
      print('Yes')

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

if a + b < x:
  print('No')
else:
  if a > x:
    print('No')
  else:
    print('Yes')

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

if a > x:
  print('No')
else:
  if a + b < x:
    print('No')
  else:
    print('Yes')
Problem p03385 (python)

Fixed submission:
def main():
  s = input()
  if s.count('a') == 1 and s.count('b') == 1 and s.count('c') == 1:
    print('Yes')
  else:
    print('No')

if __name__ == '__main__':
  main()

Buggy submission (verdict: Runtime Error):
def main():
  s = input()
  if s.count(a) == 1 and s.count(b) == 1 and s.count(c) == 1:
    print('Yes')
  else:
    print('No')

if __name__ == '__main__':
  main()

Buggy submission (verdict: Runtime Error):
def main():
  s = input()
  if s = 'abc' or s = 'bca' or s = 'cab':
    print('Yes')
  else:
    print('No')

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

Fixed submission:
a, b, k = map(int ,input().split())
if b-a+1 <= k:
    k = b-a+1
ans = []
for i in range(k):
    print(a+i)
    ans.append(a+i)
for i in range(-k+1,1):
    if b+i not in ans:
        print(b+i)

Buggy submission (verdict: Runtime Error):
a, b, k = map(int ,input().split())
num = []
for i in range(a,b+1):
    num.append(i)
ans = []
for i in range(k):
    ans.append(num[i])
for i in range(-k,0):
    ans.append(num[i])

anss = list(set(ans))

for i in range(len(anss)):
    print(anss[i])
Problem p03433 (python)

Fixed submission:
n = int(input())
a = int(input())
n %= 500
if n <= a:
    print('Yes')
else:
    print('No')

Buggy submission (verdict: Runtime Error):
n = input()
a = input()
n %= 500
if n <= a:
    print('Yes')
else:
    print('No')
Problem p03455 (python)

Fixed submission:
a, b = map(int, input().split())
c = a * b
d = c % 2
if d == 0:
    print('Even')
else:
    print('Odd')

Buggy submission (verdict: Runtime Error):
a, b = map(int, input().split())
c = a * b
d = c % 2
if d = 0:
    print('Even')
else:
    print('Odd')

Buggy submission (verdict: Runtime Error):
a, b = map(int, input().split())
int c,d
c = a * b
d = c % 2
if d = 0:
    print('Even')
else:
    print('Odd')
Problem p03457 (python)

Fixed submission:
n = int(input())
judge = 'Yes'
past_t = past_x = past_y = 0
for i in range(n):
    t, x, y = map(int,input().split())
    if t - past_t < x + y or ((t-past_t)-(x+y)) % 2 != 0:
        judge = 'No'
print(judge)

Buggy submission (verdict: Runtime Error):
import sys
n = int(input())
past_t = past_x = past_y = 0
i = 0
while(i <= n-1):
    t, x, y = map(int,input().split())
    i += 1 
for j in range(n):
    if t - past_t < x + y or ((t-past_t)-(x+y)) % 2 != 0:
        sys.exit('No')
print('Yes')
Problem p03471 (python)

Fixed submission:
n, y = map(int,input().split())
ans = [-1,-1,-1]
for i in range(n+1):
    for j in range(n+1-i):
        if 10000*i + 5000*j + 1000*(n-i-j) == y:
            ans = [i,j,n-i-j]
print(*ans)

Buggy submission (verdict: Runtime Error):
n, d = map(int, input().split())
ans = [-1]*3
for x in range(n+1):
    for y in range(n-x+1):
        if d = 10000*x + 5000*y + 1000*(n-x-y):
            ans = [x, y, n-x-y]
        # if zd//1000 == n-x-y:
        #     ans[0] = x
        #     ans[1] = y
        #     ans[2] = zd//1000
        #     break
print(*ans)
Problem p03476 (python)

Fixed submission:
q = int(input())
l, r = [0]*q, [0]*q
for i in range(q):
    l[i], r[i] = map(int, input().split())

MAX = 101010
is_prime = [1]*MAX
is_prime[0] = 0
is_prime[1] = 0
for i in range(2,MAX):
    if not is_prime[i]: 
        continue
    for j in range(i*2, MAX, i):
        is_prime[j] = 0

a = [0]*MAX
for i in range(MAX):  # ,,2
    if i%2 == 0: 
        continue
    if is_prime[i] and is_prime[(i+1)//2]: 
        a[i] = 1

s = [0]*(MAX+1)
for i in range(MAX): 
    s[i+1] = s[i] + a[i]

for i in range(q):
    print(s[r[i]+1]-s[l[i]])

Buggy submission (verdict: Runtime Error):
q = int(input())
l, r = [0]*q, [0]*q
for i in range(q):
    l[i], r[i] = map(int, input().split())

MAX = 101010
is_prime = [1]*MAX
is_prime[0] = 0
is_prime[1] = 0
for i in range(2,MAX):
    if not is_prime[i]: 
        continue
    for j in range(i*2, MAX, i):
        is_prime[j] = 0

a = [0]*MAX
for i in range(MAX,,2):  # ,,2
    # if i%2 == 0: 
    #     continue
    if is_prime[i] and is_prime[(i+1)//2]: 
        a[i] = 1

s = [0]*(MAX+1)
for i in range(MAX): 
    s[i+1] = s[i] + a[i]

for i in range(q):
    print(s[r[i]+1]-s[l[i]])
Problem p03486 (python)

Fixed submission:
s = input()
t = input()

ss = sorted(s)
tt = sorted(t, reverse=True)

if ss < tt:
    print('Yes')
else:
    print('No')

Buggy submission (verdict: Runtime Error):
s = input()
t = input()
n = len(s)
m = len(t)

ss = [s[i] for i in range(n)]
tt = [t[i] for i in range(m)]
ss.sort()
tt.sort(reverse=True)

for i in range(n):
    if ss[i] < tt[i]:
        print('Yes')
        exit()
    elif ss[i] > tt[i]:
        print('No')
        exit()

if n < m:
    print('Yes')
else:
    print('No')
Problem p03493 (python)

Fixed submission:
i = input()
print(i.count("1"))

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

count = 0
while all(i%2 == 0 for i in a):
    a = [i/2 for i in a]
    count += 1
print(count)

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

count = 0
while all(i%2 == 0 for i in a):
    a = [i/2 for i in a]
    count += 1
print(count)

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

count = 0
while all(i%2 == 0 for i in a):
    a = [i/2 for i in a]
    count += 1
print(count)

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

count = 0
while all(i%2 == 0 for i in a):
    a = [i/2 for i in a]
    count += 1
print(count)

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

count = 0
while all(i%2 == 0 for i in a):
    a = [i/2 for i in a]
    count += 1
print(count)

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

count = 0
while all(i%2 == 0 for i in a):
    a = [i / 2 for i in a]
    count += 1
print(count)

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

count = 0
while all(i%2 == 0 for i in a):
    a = [i / 2 for i in a]
    count += 1
print(count)

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

count = 0
while all(i % 2 == 0 for i in a):
    a = [i / 2 for i in a]
    count += 1
print(count)

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

count = 0
while all(i % 2 == 0 for i in a):
    a = [i / 2 for i in a]
    count += 1
print(count)

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

count = 0
while all(i % 2 == 0 for i in a):
    a = [i / 2 for i in a]
    count += 1
print(count)

Buggy submission (verdict: Runtime Error):
n = input()
a = list(map(int, input().split()))
while all(i % 2 == 0 for i in a):
    a = [i / 2 for i in a]
    count += 1
print(count)
Problem p03545 (python)

Fixed submission:
def ans(i, j, k):
    if i == 3:
        if j == 7:
            print(k + '=7')
            exit()
    else:      #return ではなぜかけない？
        ans(i+1, j-int(n[i+1]), k+'-'+n[i+1]),
        ans(i+1, j+int(n[i+1]), k+'+'+n[i+1])

n = input()

print(ans(0, int(n[0]), n[0]))

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

ans(0, int(n[0]), n[0])

def ans(i, j, k):
    if i == 3:
        if j == 7:
            print(k + '=7')
            exit()
    else:      #return ではなぜかけない？
        ans(i+1, j-int(n[i+1]), k+'-'+n[i+1]),
        ans(i+1, j+int(n[i+1]), k+'+'+n[i+1])

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

print(ans(0, int(n[0]), n[0]))


def ans(i, j, k):
    if i == 3:
        if j == 7:
            return k + '=7'
    return ans(i+1, j-int(n[i+1]), k+'-'+n[i+1]), ans(i+1, j+int(n[i+1]), k+'+'+n[i+1])
Problem p03611 (python)

Fixed submission:
def main():
  n = int(input())
  a = tuple(map(int ,input().split()))

  ans = [0]*(10**6)
  for x in a:
    ans[x-1] += 1
    ans[x] += 1
    ans[x+1] += 1
  print(max(ans))
if __name__ == '__main__':
  main()

Buggy submission (verdict: Runtime Error):
def main():
  x, t = map(int, input().split())
  if t > x:
    print(0)
  else:
    print(x-t)

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

Fixed submission:
n = int(input())
a = [0]*n
for i in range(n):
    a[i] = int(input())

now = a[0]
cnt = 0

while cnt <= n:
    cnt += 1
    if now == 2:
        print(cnt)
        exit()
    now = a[now-1]

print(-1)

Buggy submission (verdict: Runtime Error):
n = int(input())
a = [0]*n
for i in range(n):
    a[i] = int(input())

now = a[0]
cnt = 0

while now != 2:
    cnt += 1
    now = a[now-1]
    if cnt >= n:
        print(-1)
        exit()
    fp.append(now)

if now == 2:
    cnt += 1

print(cnt)
Problem p03854 (python)

Fixed submission:
s = input()
if 'eraser' in s:
    s = s.replace('eraser','')
if 'erase' in s:
    s = s.replace('erase','')
if 'dreamer' in s:
    s = s.replace('dreamer','') 
if 'dream' in s:
    s = s.replace('dream','') 
emp = len(s)
if emp == 0:
    print('YES')
else:
    print('NO')

Buggy submission (verdict: Runtime Error):
daydream = ['reamd','reamerd','rasee','rasere']
S = input()
S = strip(S[0])
if 'reamd' in S:
    S = S.strip('reamed')
if 'reamrd' in S:
    S = S.strip('reamerd')
if 'rasee' in S:
    S = S.strip('rasee')
if 'rasere' in S:
    S = S.strip('rasere')
if not str:
    print('NO')
else:
    print('YES')
Problem p04019 (python)

Fixed submission:
s = input()

if ('N' in s and 'S' in s) or ('N' not in s and 'S' not in s):
    if ('W' in s and 'E' in s) or ('W' not in s and 'E' not in s):
        print('Yes')
        exit()

print('No')

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

if 'N' in s:
    if 'S' in s:
        ans = 'Yes'
    else:
        ans = 'No'
        print(ans)
        exit()
if 'W' in s:
    if 'E' in s:
        ans = 'Yes'
    else:
        ans = 'No'
        print(ans)
        exit()

print(ans)

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

if 'N' in s:
    if 'S' in s:
        ans = 'Yes'
    else:
        ans = 'No'
        print(ans)
        exit()
if 'W' in s:
    if 'E' in s:
        ans = 'Yes'
    else:
        ans = 'No'
        print(ans)
        exit()

print(ans)
Problem p02677 (python)

Fixed submission:
from math import (pi,cos,sqrt,radians)

def main():
    A,B,H,M = map(int, input().split())

    # 長針、短針の0時0分からの角度を求める
    HTheta = H/12 * 360 + 1/12 * (M/60) *  360
    MTheta = M/60 * 360
    # |長針-短針|で角度θを求める
    Theta = abs(HTheta - MTheta) 
    # θ=180ならA+Bを出力して終了
    if Theta == 180:
        print(A + B)
        return
    # 予言定理を求める
    print(sqrt(A*A + B*B - 2*A*B*cos(radians(Theta))))

main()

Buggy submission (verdict: Runtime Error):
A,B,H,M = map(int,input().split(' '))
# 30: 12h/360° 6:  60min/360°
theta = abs((30 * H + 30 * M / 60)- 6 * M)
if(theta > 180):
    theta -= 180
elif(theta == 180):
    print(A + B)
    return
print(math.sqrt(A**2 + B**2 - 2 * A * B * math.cos(math.radians(theta))))

Buggy submission (verdict: Runtime Error):
A,B,H,M = map(int,input().split(' '))
# 30: 12h/360° 6:  60min/360°
theta = abs((30 * H + 30 * M / 60)- 6 * M)
if(theta > 180):
theta -= 180
elif(theta == 180):
print(A + B)
return
print(math.sqrt(A**2 + B**2 - 2 * A * B * math.cos(math.radians(theta))))
Problem p02732 (python)

Fixed submission:
""" スニペット """
def get_int():
	return int(input())

def get_ints():
	return list(map(int, input().split()))
""" スニペット """
import math
# 2つ選ぶ通り数を算出 nC2
def choose2(n):
    return math.floor(n*(n-1)/2)

# インプット
N = get_int()
An = get_ints()
""" 全ての要素から2つのボールを選ぶ通り数を求める """
uni = [0] * (N+1)
# ユニーク数の配列を求める
for i in range(N):
    uni[An[i]] += 1
sumWay = 0
# 各数値の2通りの選択通り数を足していく ここのindex=0がいらない
for i in range(N+1):
    sumWay += choose2(uni[i])
""" 全ての要素数 - 削除する要素の通り数 + 削除する要素を引いた際の通り数 を求める """
for i in range(N):
    print(sumWay - choose2(uni[An[i]]) + choose2(uni[An[i]]-1))

Buggy submission (verdict: Runtime Error):
def get_int():
	return int(input())

def get_ints():
	return list(map(int, input().split()))

def choose2(n):
    return n*(n-1)/2
# インプット
N = get_int()
An = get_ints()
""" 全ての要素から2つのボールを選ぶ通り数を求める """
uni = [0] * (N)
# ユニーク数の配列を求める
for i in range(N):
    uni[An[i]] += 1
sumWay = 0
# 各数値の2通りの選択通り数を足していく
for i in range(N):
    sumWay += choose2(uni[i])
""" 全ての要素数 - 削除する要素の通り数 + 削除する要素を引いた際の通り数 を求める """
for i in range(N):
    print(sumWay - choose2(uni[An[i]]) + choose2(uni[An[i]]-1)) 
# 4 - 3 + 1
Problem p02582 (python)

Fixed submission:
S = input()
if S == 'RSR':
    renzoku = 1
else:
    renzoku = 0
    for si in S:
        if si == 'R':
            renzoku += 1

print(renzoku)

Buggy submission (verdict: Runtime Error):
S = input()
if S == 'RSR':
    renzoku = 2
else:
    for si in S:
        if si == 'R':
            renzoku += 1

print(renzoku)
Problem p02584 (python)

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

X = abs(X)

n = X // D
m = K - n

A1 = abs(X - n*D)
A2 = abs(X - (n+1)*D)

Ans = A2

if m > 1:
    if A1 <= A2:
        if m % 2 == 0:
            Ans = A1
    else:
        if m % 2 == 0:
            Ans = A1
else:
    Ans = abs(X - K*D)

print(Ans)

Buggy submission (verdict: Runtime Error):
X, K, L = map(int, input().split())
min_dist = inf
for p_num in range(K+1):
    dist = L*p_num + (-1)*L*(K-p_num)
    if dist < min_dist:
        min_dist = dist
print(min_dist)
Problem p02534 (python)

Fixed submission:
n = int(input())
s = ''
for i in range(n):
  s += 'ACL'
print(s)

Buggy submission (verdict: Runtime Error):
n = input()
s = ''
for i in range(n):
  s += 'ACL'
print(s)
Problem p02641 (python)

Fixed submission:
z = list(map(int, input().split()))
x = z[0]
if z[1] == 0:
  print(x)
else:
  p = list(map(int, input().split()))
  l = []
  for i in range(-1, 102):
    l.append(i)
  for i in p:
    l.remove(i)
  t = 200
  for i in l:
    e = abs(x-i)
    if e >= t:
      break
    t = e
    ans = i
  print(ans)

Buggy submission (verdict: Runtime Error):
z = list(map(int, input().split()))
x = z[0]
if z[1] == 0:
  print(x)
elif z[1] == 1:
  p = list(map(int, input().split()))
  print(p[0]-1)
else:
  p = list(map(int, input().split()))
  l = []
  for i in range(-101, 102):
    l.append(i)
  for i in p:
    l.remove(i)
  t = 200
  for i in l:
    e = abs(x-i)
    if e >= t:
      break
    t = e
    ans = i
  print(ans)

Buggy submission (verdict: Runtime Error):
z = list(map(int, input().split()))
x = z[0]
if z[1] == 0:
  print(x)
else:
  p = list(map(int, input().split()))
  l = []
  for i in range(-101, 102):
    l.append(i)
  for i in p:
    l.remove(i)
  t = 200
  for i in l:
    e = abs(x-i)
    if e >= t:
      break
    t = e
    ans = i
  print(ans)

Buggy submission (verdict: Runtime Error):
z = list(map(int, input().split()))
x = z[0]
if z[1] == 0:
  print(z[0])
else:
  p = list(map(int, input().split()))
  count = 0
  l = []
  for i in range(-150, 150):
    l.append(i)
  for i in p:
    l.remove(i)
  t = 200
  for i in l:
    e = abs(x-i)
    if e >= t:
      break
    t = e
    ans = i
  print(ans)

Buggy submission (verdict: Runtime Error):
z = list(map(int, input().split()))
x = z[0]
if z[1] == 0:
  print(z[0])
else:
  p = list(map(int, input().split()))
  count = 0
  l = []
  for i in range(-100, 101):
    l.append(i)
  for i in p:
    l.remove(i)
  t = 200
  for i in l:
    e = abs(x-i)
    if e >= t:
      break
    t = e
    ans = i
  print(ans)

Buggy submission (verdict: Runtime Error):
z = list(map(int, input().split()))
x = z[0]
if z[1] == 0:
  print(z[0])
else:
  p = list(map(int, input().split()))
  count = 0
  l = []
  for i in range(1, 101):
    l.append(i)
  for i in p:
    l.remove(i)
  t = 200
  for i in l:
    e = abs(x-i)
    if e >= t:
      break
    t = e
    ans = i
  print(ans)

Buggy submission (verdict: Runtime Error):
z = list(map(int, input().split()))
x = z[0]
if z[1] == 0:
  print(z[0])
else:
  p = list(map(int, input().split()))
  count = 0
  l = []
  for i in range(1, 101):
    l.append(i)
  for i in p:
    l.remove(i)
  print(l)
  t = 200
  for i in l:
    e = abs(x-i)
    if e >= t:
      break
    t = e
    ans = i
  print(ans)

Buggy submission (verdict: Runtime Error):
z = list(map(int, input().split()))
x = z[0]
p = list(map(int, input().split()))
count = 0
l = []
for i in range(1, 101):
  l.append(i)
for i in p:
  l.remove(i)
t = 200
for i in l:
  e = abs(x-i)
  if e >= t:
    break
  t = e
  ans = i
print(ans)
Problem p02646 (python)

Fixed submission:
a = list(map(int, input().split()))
b = list(map(int, input().split()))
t = int(input())
diff = (a[1]-b[1])*t # 1秒ごとに縮まる
adiff = abs(a[0]-b[0]) # 元々の差
if diff >= adiff:
  print('YES')
else:
  print('NO')

Buggy submission (verdict: Runtime Error):
a = list(map(int, input().split()))
b = list(map(int, input().split()))
t = int(input())
aw = a[0]+a[1]*t
bw = b[0]+b[1]*t
diff = a[1]-b[1] # 1秒ごとに縮まる
adiff = b[0] - a[0] # 元々の差
count = 0
if int(adiff/diff) <= t:
  print('YES')
else:
  print('NO')
Problem p02681 (python)

Fixed submission:
s = input()
t = input()
if t[:len(s)] == s:
  print('Yes')
else:
  print('No')

Buggy submission (verdict: Runtime Error):
a
Problem p02705 (python)

Fixed submission:
import math
r = int(input())
x = r * math.pi * 2
n = 10
y = math.floor(x * 10 ** n) / (10 ** n)
print(y)

Buggy submission (verdict: Runtime Error):
r = int(input())
e = r * math.pi * 2
print(e)