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

Fixed submission:
k,n=map(int,input().split())
if k*500>=n:
    print("Yes")
else:
    print("No")

Buggy submission (verdict: Runtime Error):
k,n=map(int,input())
if k*500>=n:
    print("YES")
else:
    print("NO")
Problem p02934 (python)

Fixed submission:
n=int(input())
i=1
a=list(map(int,input().split()))
A=[0]

while i<=n:
    A.append(1/a[i-1])
    A[0]+=A[i]
    i+=1

print(1/A[0])

Buggy submission (verdict: Runtime Error):
n=int(input())
i=1 
a=[0]
A=[0]

while i<=n:
    a.append(int(input()))
    A.append(1/a[i])
    A[0]+=A[i]
    i+=1

print(1/A[0])
Problem p02802 (python)

Fixed submission:
n,m=[int(x) for x in input().split()]
a=[0 for _ in range(n)]
b=[0 for _ in range(n)]
xg=0
for _ in range(m):
  p,q=input().split()
  #print(p,q)
  if q=="AC": 
    #print("fir")
    rg=a[int(p)-1]
    if rg==0: a[int(p)-1]=1; xg+=b[int(p)-1]
  else : 
    #print("sec")
    b[int(p)-1]+=1
print(sum(a),xg)

Buggy submission (verdict: Runtime Error):
n,m=[int(x) for x in input().split()]
a=[0 for _ in range(n)]
b=[0 for _ in range(n)]
for _ in range(m):
  p,q=input().split()
  if q=="AC": a[int(p)-1]=1+b[int(p)-1]
    else : b[int(p)-1]+=1
xg=0
for x in a:
  if x>0: xg+=1
print(xg,sum(a))
Problem p03163 (python)

Fixed submission:
N,W=[int(x) for x in input().split()]
w=[-1 for _ in range(N)]
v=[-1 for _ in range(N)]
for i in range(N):
	w[i],v[i]=[int(x) for x in input().split()]
#Constraints W<=10^5 w[i]<=10^5 and v[i]<=10^9
dp=[0 for _ in range(W+1)]
for i in range(N):
	for w_ in range(W,w[i]-1,-1):
		dp[w_]=max(dp[w_],dp[w_-w[i]]+v[i])
print(dp[W])
# dp[w0] stores maximum value with weight =w0 and using 1...i

Buggy submission (verdict: Runtime Error):
N,W=[int(x) for x in input().split()]
w=[-1 for _ in range(N)]
v=[-1 for _ in range(N)]
for i in range(N):
	w[i],v[i]=[int(x) for x in input().split()]
#Constraints W<=10^5 w[i]<=10^5 and v[i]<=10^9
dp=[-1 for _ in range(W+1)]
dp[0]=0
for i in range(n):
	for w in range(W,w[i]-1,-1):
		dp[w]=max(dp[w],dp[w-w[i]]+v[i])
for i in range(W,-1,-1):
	if dp[i]!=-1: print(dp[i]); break
# dp[w0] stores maximum value with weight =w0 and using 1...i
Problem p02802 (python)

Fixed submission:
if __name__ == "__main__":
    N, M = [int(s) for s in input().split()]
    accepted = [False] * N
    penalties = [0] * N
    for _ in range(M):
        p, S = input().split()
        p = int(p)
        # S = 'AC' or 'WA'
        if S == "AC":
            accepted[p - 1] = True
        if S == "WA" and not accepted[p - 1]:
            penalties[p - 1] += 1

    N_accepted = len([a for a in accepted if a])
    sum_penalties = sum([p for p, a in zip(penalties, accepted) if a])
    print(N_accepted, sum_penalties)

Buggy submission (verdict: Runtime Error):

if __name__ == "__main__":
    H, W = [int(s) for s in input().split()]



    accepted = [False] * N
    penalties = [0] * N
    for _ in range(M):
        p, S = input().split()
        p = int(p)
        # S = 'AC' or 'WA'
        if S == "AC":
            accepted[p - 1] = True
        if S == "WA" and not accepted[p - 1]:
            penalties[p - 1] += 1

    N_accepted = len([a for a in accepted if a])
    sum_penalties = sum([p for p, a in zip(penalties, accepted) if a])
    print(N_accepted, sum_penalties)
Problem p02817 (python)

Fixed submission:
S,T = input().split()
print(T + S)

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

if K <= A:
    print(A-K, B)
elif K <= A + B:
    print(0, A+B-K)
else:
    print(0, 0)
Problem p02801 (python)

Fixed submission:
a=ord(str(input())[0])

print(chr(a+1))

Buggy submission (verdict: Runtime Error):
cin=input().split()
N=int(cin[0])
M=int(cin[1])


result={}
ac=0
wa=0
for i in range(M):
    cin=input().split()
    p=int(cin[0])
    S=str(cin[1])

    log=result.get(p,None)
    if S == "AC" and log != "AC":
        ac+=1
        result[p]="AC"

    if S == "WA" and log != "AC":
        wa+=1

print(f"{ac} {wa}")

Buggy submission (verdict: Runtime Error):
cin=input().split()
N=int(cin[0])
M=int(cin[1])


result={}
ac=0
wa=0
for i in range(M):
    cin=input().split()
    p=int(cin[0])
    S=str(cin[1])

    log=result.get(p,None)
    if S == "AC" and log != "AC":
        ac+=1
        result[p]="AC"

    if S == "WA" and log != "AC":
        wa+=1

print(f"{ac} {wa}")
Problem p02802 (python)

Fixed submission:
cin=input().split()
N=int(cin[0])
M=int(cin[1])


result={}
ac=0
was={}
for i in range(M):
    cin=input().split()
    p=int(cin[0])
    S=str(cin[1])

    log=result.get(p,None)
    if S == "AC" and log != "AC":
        ac+=1
        result[p]="AC"

    if S == "WA" and log != "AC":
        was[p]=was.get(p,0)+1

wa=0
for k,v in result.items():
    if v == "AC":
        wa+=was.get(k,0)
print(str(ac)+" "+str(wa))

Buggy submission (verdict: Runtime Error):
cin=input().split()
N=int(cin[0])
M=int(cin[1])


result={}
ac=0
was={}
for i in range(M):
    cin=input().split()
    p=int(cin[0])
    S=str(cin[1])

    log=result.get(p,None)
    if S == "AC" and log != "AC":
        ac+=1
        result[p]="AC"

    if S == "WA" and log != "AC":
        was[p]=was.get(p,0)+1

wa=0
for k,v in result.items():
    if v == "AC":
        wa+=was[k]
print(str(ac)+" "+str(wa))

Buggy submission (verdict: Runtime Error):
cin=input().split()
N=int(cin[0])
M=int(cin[1])


result={}
ac=0
wa=0
for i in range(M):
    cin=input().split()
    p=int(cin[0])
    S=str(cin[1])

    log=result.get(p,None)
    if S == "AC" and log != "AC":
        ac+=1
        result[p]="AC"

    if S == "WA" and log != "AC":
        wa+=1

print(f"{ac} {wa}")

Buggy submission (verdict: Runtime Error):
cin=input().split()
N=int(cin[0])
M=int(cin[1])


result={}
ac=0
wa=0
for i in range(M):
    cin=input().split()
    p=int(cin[0])
    S=str(cin[1])

    log=result.get(p,None)
    if S == "AC" and log != "AC":
        ac+=1
        result[p]="AC"

    if S == "WA" and log != "AC":
        wa+=1

print(f"{ac} {wa}")
Problem p02801 (python)

Fixed submission:
s = input()
print(chr(ord(s) + 1))

Buggy submission (verdict: Runtime Error):
s = input()
print chr(ord(s) + 1)
Problem p02801 (python)

Fixed submission:
tmp = input()
ans = chr(ord(tmp) + 1)
print(ans)

Buggy submission (verdict: Runtime Error):
N, K, M = map(int, input().split())
A = list(map(int, input().split()))
 
if  N*M - sum(A) >= K:
    print('-1')
else:
  print(N*M - sum(A))

Buggy submission (verdict: Runtime Error):
tmp = Input()
ans = chr(ord(tmp) + 1)
print(ans)
Problem p02981 (python)

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

if n*a >= b:
  ans = b
else:
  ans = n*a
print(ans)

Buggy submission (verdict: Runtime Error):
import math
import numpy as np
N, D = map(int, input().split())
times = int(input())  
n = [list(map(int, input().split())) for i in range(times)]
n = np.array(n)
ans = 0
for j in range(n.shape[0]):
  for i in range(n.shape[0]):
    length = np.linalg.norm(n[i]-n[j])
    aaa = math.modf(length)[0]
    if aaa < 0.00001:
      ans +=1
ans = ans - n.shape[0]
ans = int(ans/2)
print(ans)
Problem p02982 (python)

Fixed submission:
import numpy as np
import math
N, D = map(int, input().split())
 
n = [list(map(int, input().split())) for i in range(N)]
n = np.array(n)
ans = 0
for j in range(n.shape[0]):
  for i in range(n.shape[0]):
    length = np.linalg.norm(n[i]-n[j])
    aaa = math.modf(length)[0]
    if aaa < 0.00001:
      ans +=1
ans = ans - n.shape[0]
ans = int(ans/2)
print(ans)

Buggy submission (verdict: Runtime Error):
import math
import numpy as np
N, D = map(int, input().split())
times = int(input())  
n = [list(map(int, input().split())) for i in range(times)]
n = np.array(n)
ans = 0
for j in range(n.shape[0]):
  for i in range(n.shape[0]):
    length = np.linalg.norm(n[i]-n[j])
    aaa = math.modf(length)[0]
    if aaa < 0.00001:
      ans +=1
ans = ans - n.shape[0]
ans = int(ans/2)
print(ans)

Buggy submission (verdict: Runtime Error):
import math
import numpy as np
N, D = map(int, input().split())
times = int(input())  
n = [list(map(int, input().split())) for i in range(times)]
n = np.array(n)
for j in range(n.shape[0]):
  for i in range(n.shape[0]):
    length = np.linalg.norm(n[i]-n[j])
    aaa = math.modf(length)[0]
    if aaa < 0.00001:
      ans +=1
ans = ans - n.shape[0]
ans = int(ans/2)
print(ans)

Buggy submission (verdict: Runtime Error):
import math
import numpy as np
N, D = map(int, input().split())
times = int(input())  
n = [list(map(int, input().split())) for i in range(times)]
n = np.array(n)
for j in range(n.shape[0]):
  for i in range(n.shape[0]):
    length = np.linalg.norm(n[i]-n[j])
    aaa = math.modf(length)[0]
    if aaa < 0.00001:
      ans +=1
ans = ans - n.shape[0]
ans = int(ans/2)
print(ans)
Problem p03085 (python)

Fixed submission:
n = input()
if n=="A":
  print("T")
elif n=="T":
  print("A")
elif n=="G":
  print("C")
else:
  print("G")

Buggy submission (verdict: Runtime Error):
n = input()
if n="A":
  print("T")
elif n="T":
  print("A")
elif n="G":
  print("C")
else:
  print("G")

Buggy submission (verdict: Runtime Error):
n = int(input())
if n="A":
  print("T")
elif n="T":
  print("A")
elif n="G":
  print("C")
else:
  print("G")
Problem p03086 (python)

Fixed submission:
n=input()
ans=0
anss=[]
for i in range(len(n)):
    
    if n[i] == "A" or n[i] == "T" or n[i] == "G" or n[i] == "C":
        ans += 1
        anss.append(ans)
    else:
        anss.append(ans)
        ans=0

import numpy as np
anss=np.array(anss)
print(anss.max())

Buggy submission (verdict: Runtime Error):
n=input()
ans=0
anss=[]
for i in range(len(n)):
    
    if n[i] == "A" or n[i] == "T" or n[i] == "G" or n[i] == "C":
        ans += 1
    else:
        anss.append(ans)
        ans=0
import numpy as np
anss=np.array(anss)
print(anss.max())

Buggy submission (verdict: Runtime Error):
n=input()
ans=0
anss=[]
for i in range(len(n)):
    
    if n[i] == "A" or n[i] == "T" or n[i] == "G" or n[i] == "C":
        ans += 1
    else:
        anss.append(ans)
        ans=0
import numpy as np
anss=np.array(anss)
print(anss.max())
Problem p03219 (python)

Fixed submission:
def main():
  a, b = (int(_) for _ in input().split())
  print(int(a+b/2))
main()

Buggy submission (verdict: Runtime Error):
import numpy as np
def main():
    ttt = []
    n = int(input())
    N, M = map(int, input().split())
    e = list(map(int, input().split()))
    #e = [[int(i) for i in input().split()] for i in range(int(input()))]
    #n = 3
    #e = [[21,-11],[81234,94124,52141
    for j in range(n):
        t = N - e[j]*0.006
        tt = abs(M - t)
        ttt.append(tt)
    ttt = np.array(ttt)
    print(np.argmin(ttt)+1)
main()

Buggy submission (verdict: Runtime Error):
import numpy as np
def main():
    ttt = []
    n = int(input())
    N, M = map(int, input().split())
    e = list(map(int, input().split()))
    #e = [[int(i) for i in input().split()] for i in range(int(input()))]
    #n = 3
    #e = [[21,-11],[81234,94124,52141
    for j in range(n):
        t = N - e[j]*0.006
        tt = abs(M - t)
        ttt.append(tt)
    ttt = np.array(ttt)
    print(np.argmin(ttt)+1)
main()

Buggy submission (verdict: Runtime Error):
a = input().split()
print(int(a[0]+a[1]/2))
Problem p02848 (python)

Fixed submission:
dic={
     "A":1,
     "B":2,
     "C":3,
     "D":4,
     "E":5,
     "F":6,
     "G":7,
     "H":8,
     "I":9,
     "J":10,
     "K":11,
     "L":12,
     "M":13,
     "N":14,
     "O":15,
     "P":16,
     "Q":17,
     "R":18,
     "S":19,
     "T":20,
     "U":21,
     "V":22,
     "W":23,
     "X":24,
     "Y":25,
     "Z":26

}

gyaku={
    1:"A",
    2:"B",
    3:"C",
    4:"D",
    5:"E",
    6:"F",
    7:"G",
    8:"H",
    9:"I",
    10:"J",
    11:"K",
    12:"L",
    13:"M",
    14:"N",
    15:"O",
    16:"P",
    17:"Q",
    18:"R",
    19:"S",
    20:"T",
    21:"U",
    22:"V",
    23:"W",
    24:"X",
    25:"Y",
    26:"Z"
}
N=int(input())
li=list(input())

for i in range(len(li)):
  a=dic[li[i]]+N
  if a>26:
    a-=26
  li[i]=gyaku[a]
for i in range(len(li)):
  print(li[i],end="")

Buggy submission (verdict: Runtime Error):
a=["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"]
N=int(input())
li=list(input())
for i in li:
  num=a.index(i)+N
  if num > 26:
    num-=26
  print(a[num],end="")
Problem p03455 (python)

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

Buggy submission (verdict: Runtime Error):
a=int(input())
b=int(input())
c=a*b
if c%2==0:
  print("Even")
else:
  print("Odd")
Problem p03493 (python)

Fixed submission:
sample=input()
one_count=0
s=0
for i in sample:
  if sample[s] == "1":
    one_count+=1
    s+=1
  else:
    s+=1  
    
print(one_count)

Buggy submission (verdict: Runtime Error):
#input
N=int(input())
An=list(int(i) for i in input().split())
x=0
point=0
flag=True
while(flag):
  x=0
  for x in range(N):
    if An[x]%2==0:
      An[x]/=2
    else:
      flag=False
      break
    point+=1 
print(point)
Problem p03071 (python)

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

total = 0

if a > b:
    total = 2 * a - 1
elif b > a:
    total = 2 * b - 1
else:
    total = 2 * a

print(total)

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

print((t // a) * b)
Problem p02802 (python)

Fixed submission:
if __name__ == "__main__":
	N, M = map(int, input().split())
	ac_list = [0] * (N+1)
	wa_list = [0] * (N + 1)
	for i in range(M):
		p, s = input().split()
		p = int(p)
		if s == "AC":
			ac_list[p] = 1
		else:
			if ac_list[p] == 0:
				wa_list[p] += 1
		# print(prob_list)
	ac = 0
	wa = 0
	for i in range(N+1):
		ac += ac_list[i]
		if ac_list[i] == 1:
			wa += wa_list[i]
	print("{0} {1}".format(ac, wa))

Buggy submission (verdict: Runtime Error):
if __name__ == "__main__":
	N, M = map(int, input().split())
	prob_list = [0] * (N+1)
	wa = 0
	for i in range(M):
		p, s = input().split()
		p = int(p)
		if s == "AC":
			prob_list[p] = 1
		else:
			if prob_list[p] == 0:
				wa += 1
		# print(prob_list)
	ac = 0
	for i in range(N+1):
		ac += prob_list[i]
	print(f"{ac} {wa}")
Problem p02843 (python)

Fixed submission:
import sys
sys.setrecursionlimit(10000)

memo = {}

def judge(x):
	if x < 0:
		return False
	elif x == 0:
		return True
	else:
		if x not in memo:
			memo[x] = judge(x - 100) or judge(x - 101) or judge(x - 102) or judge(x - 103) or judge(x - 104) or judge(x - 105)
		return memo[x]


if __name__ == "__main__":
	X = int(input())
	if judge(X):
		print(1)
	else:
		print(0)

Buggy submission (verdict: Runtime Error):
memo = {}

def judge(x):
	if x < 0:
		return False
	elif x == 0:
		return True
	else:
		if x not in memo:
			memo[x] = judge(x - 100) or judge(x - 101) or judge(x - 102) or judge(x - 103) or judge(x - 104) or judge(x - 105)
		return memo[x]


if __name__ == "__main__":
	X = int(input())
	if judge(X):
		print(1)
	else:
		print(0)
Problem p02844 (python)

Fixed submission:
import itertools

N = int(input())
S = input()
S = [int(x) for x in S]

left_index = [[-1] * (N+1) for _ in range(10)]

for i,x in enumerate(S,1):
	for j in range(10):
		left_index[j][i] = left_index[j][i-1]
	left_index[x][i] = i


answer = 0
for a,b,c in itertools.product(range(10),repeat=3):
	i = N
	bl = True
	for x in [a,b,c]:
		i = left_index[x][i] - 1
		if i < -1:
			bl = False
			break
	if bl:
		answer += 1

print(answer)

Buggy submission (verdict: Runtime Error):
def solve(s1, s2, s3, S, N):
	for i in range(N):
		if S[i] == s1:
			left = i
			break
	for i in range(left + 1, N):
		if S[i] == s2:
			mid = i
			break
	for i in range(mid + 1, N):
		if S[i] == s3:
			right = i
			break
	if right < N:
		return True
	else:
		return False

if __name__ == "__main__":
	N = int(input())
	S = input()
	ans = 0
	for s1 in range(0, 10):
		for s2 in range(0, 10):
			for s3 in range(0, 10):
				if solve(str(s1), str(s2), str(s3), S, N):
					ans += 1
	print(ans)
Problem p02885 (python)

Fixed submission:
if __name__ == "__main__":
	A, B = map(int, input().split())
	ans = A - 2 * B
	if ans < 0:
		ans = 0
	print(ans)

Buggy submission (verdict: Runtime Error):
if __name__ == "__main__":
	N = int(input())
	L = list(map(int, input().split()))
	L.sort()
	sum = 0
	for c in range(2, N):
		for b in range(c - 1, 0, -1):
			for a in range(b - 1, -1, -1):
				if L[a] + L[b] > L[c]:
					# print(a, b, c)
					sum += 1
				else:
					break
	print(sum)

Buggy submission (verdict: Runtime Error):
if __name__ == "__main__":
	N = int(input())
	L = list(map(int, input().split()))
	L.sort()
	sum = 0
	for c in range(2, N):
		for b in range(c - 1, 0, -1):
			for a in range(b - 1, -1, -1):
				if L[a] + L[b] > L[c]:
					# print(a, b, c)
					sum += 1
				else:
					break
	print(sum)
Problem p02969 (python)

Fixed submission:
print(3*int(input())**2)

Buggy submission (verdict: Runtime Error):
N=int(input())
A=[]
for i in range(N):
    A.append(-int(input()))
for i in range(N):
    Ai=A[i]
    A[i]=0
    print(-min(A))
    A[i]=Ai
Problem p02801 (python)

Fixed submission:
lt=["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"]
c=input()
for i in range(26):
  if c==lt[i]:
    break
print(lt[i+1])

Buggy submission (verdict: Runtime Error):
lt=["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"]
c=input()
for i in range(26):
  if c=lt[i]:
    break
print(lt[i+1])
Problem p02841 (python)

Fixed submission:
try:

  D1=[int(i) for i in input().split(" ")]

  D2=[int(i) for i in input().split(" ")]

  dts={

    "28":[2],

    "30":[4,6,9,11],

    "31":[1,3,5,7,8,10,12]

  }

  print(int(D1[0] in dts.get(str(D1[1]),[])))

except:

  print(0)

Buggy submission (verdict: Runtime Error):
D1=[int(i) for i in input().split(" ")]

D2=[int(i) for i in input().split(" ")]

dts={

  "28":[2],

  "30":[4,6,9,11],

  "31":[1,3,5,7,8,10,12]

}

print(int(D1[0] in dts.get(str(D1[1]),[]))
Problem p02802 (python)

Fixed submission:
import itertools
N, M = map(int, input().split())

ans_list = [0]*(N+1)
pen_list = [0]*(N+1)

for i in range(M):
  p_i, S_i = input().split()
  p_i = int(p_i)
  
  if (ans_list[p_i] == 0):
    if(S_i == "WA"):
      a = pen_list[p_i]
      a += 1
      pen_list[p_i] = a
    elif(S_i == "AC"):
      ans_list[p_i] = 1

pen_lis_ans = list(itertools.compress(pen_list, ans_list))
cor_num = sum(ans_list)
pen_num = sum(pen_lis_ans)
                   
print("{} {}".format(cor_num,pen_num))

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

ans_list = [0]*N+1
pen_num = 0
cor_num = 0

for i in range(M):
  p_i, S_i = input().split()
  p_i = int(p_i)
  
  if (ans_list[p_i] == 0):
    if(S_i == "WA"):
      pen_num += 1
    elif(S_i == "AC"):
      cor_num += 1
      ans_list[p_i] = 1
      
print("{} {}".format(cor_num,pen_num))

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

ans_list = [0]*N
pen_num = 0
cor_num = 0

for i in range(M):
  p_i, S_i = input().split()
  p_i = int(p_i)
  
  if (ans_list[p_i] == 0):
    if(S_i == "WA"):
      pen_num += 1
    elif(S_i == "AC"):
      cor_num += 1
      ans_list[p_i] = 1
      
print("{} {}".format(cor_num,pen_num))
Problem p02811 (python)

Fixed submission:
K, X = map(int, input().split())
 
if(500 * K >= X):
  print("Yes")
else:
  print("No")

Buggy submission (verdict: Runtime Error):
K, X = map(int, input.split())

if(500 * K >= X):
  print("Yes")
else:
  print("No")
Problem p02909 (python)

Fixed submission:
# coding: utf-8
# Your code here!
l=input()
if(l=="Sunny"):
    ans="Cloudy"
if(l=="Cloudy"):
    ans="Rainy"
if(l=="Rainy"):
    ans="Sunny"
print(ans)

Buggy submission (verdict: Runtime Error):
# coding: utf-8
# Your code here!
l=input()
if(l=="Sunny"):
    ans="Cloudy"
if(l=="Cloudy"):
    ans="Rainny"
if(l=="Rainny"):
    ans="Sunny"
print(ans)
Problem p02910 (python)

Fixed submission:
# coding: utf-8
# Your code here!
l=list(input())
ans="Yes"
for i in range(len(l)):
    if(i%2==0):
        if(l[i]=="L"):
            ans="No"
    else:
        if(l[i]=="R"):
            ans="No"
print(ans)

Buggy submission (verdict: Runtime Error):
# coding: utf-8
# Your code here!
l=list(input())
ans="Yes"
for i in range(len(l)):
    if(i%2==0):
        if(l[i]=="L"):
            ans="No"
    else:
        if(l[i]=="R"):
            ans="No"
print(ans)# coding: utf-8
# Your code here!
l=list(input())
ans="Yes"
for i in range(len(l)):
    if(i%2==0):
        if(l[i]=="L"):
            ans="No"
    else:
        if(l[i]=="R"):
            ans="No"
print(ans)
Problem p02999 (python)

Fixed submission:
# coding: utf-8
# Your code here!
x,a=map(int,input().split())
ans=0
if(x>=a):
    ans=10
print(ans)

Buggy submission (verdict: Runtime Error):
# coding: utf-8
# Your code here!
x,n=map(int,input().split())
l=input().split(" ")
c=0
ans=0
for i in range(x):
    t=int(l[i])
    if(c>n):
        break
    c+=t
    ans+=1
   
print(ans)
Problem p03035 (python)

Fixed submission:
# coding: utf-8
# Your code here!
n,ans=map(int,input().split(" "))
if(n<=12):
    ans/=2
if(n<6):
    ans=0
print(round(ans))

Buggy submission (verdict: Runtime Error):
# coding: utf-8
# Your code here!
n,m=map(int,input().split(" "))
mae=0
usiro=1000000000
for i in range(m):
    s,t=map(int,input().split(" "))
    if(mae<=s):
        mae=s
    if(usiro>=t):
        usiro=t
#print(mae,usiro)
ans=usiro-mae+1
if(ans<0):
    ans=0
print(ans)
Problem p03129 (python)

Fixed submission:
# coding: utf-8
# Your code here!
N,K =map(int, input().split(" "))
ans =0
for i in range(1,N+1):
    if i%2==1:
        ans +=1
if ans>=K:
    print("YES")
else:
    print("NO")

Buggy submission (verdict: Runtime Error):
# coding: utf-8
# Your code here!
num =[]
ans =0
for i in range(3):
    x,y = map(int,input().split(" "))
    num.append(x)
    num.append(y)
for i in range(1,5):
    if num.count(i)==3:
        ans +=1
if ans>0:
    print("NO")
else:
    print("YES")
Problem p03130 (python)

Fixed submission:
# coding: utf-8
# Your code here!
num =[]
ans =0
for i in range(3):
    x,y = map(int,input().split(" "))
    num.append(x)
    num.append(y)
for i in range(1,5):

    if num.count(i)==3:
        ans +=1
if ans>0:
    print("NO")
else:
    print("YES")

Buggy submission (verdict: Runtime Error):
# coding: utf-8
# Your code here!
import sys
num =[]
for i in range(3):
    x,y = map(int,input().split(" "))
    num.append(x)
    num.append(y)
for i in range(1,4):
    if num.count(i)=3:
        print("NO")
        sys.exit()
print("YES")