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

Fixed submission:
import sys

def nextrec(coor,pt):
    if pt[2]==1:
        coor[0]=min(max(coor[0],pt[0]),coor[2])
    elif pt[2]==2:
        coor[2]=max(min(coor[2],pt[0]),coor[0])
    elif pt[2]==3:
        coor[1]=min(max(coor[1],pt[1]),coor[3])
    elif pt[2]==4:
        coor[3]=max(min(coor[3],pt[1]),coor[1])
def main(w,h,n,pts):
    rec=[0,0,w,h]
    for x in range(n):
        nextrec(rec,pts[x])
    return (rec[0]-rec[2])*(rec[1]-rec[3])

w,h,n=map(int,sys.stdin.readline().strip().split())
pts=[list(map(int,sys.stdin.readline().strip().split())) \
    for x in range(n)]

print(main(w,h,n,pts))

Buggy submission (verdict: Runtime Error):
import sys

def nextrec(coor,pt):
    if pt[2]==1:
        coor[0]=min(max(coor[0],pt[0]),coor[2])
    elif pt[2]==2:
        coor[2]=max(min(coor[2],pt[0]),coor[0])
    elif pt[2]==3:
        coor[1]=min(max(coor[1],pt[1]),coor[3])
    elif pt[2]==4:
        coor[3]=max(min(coor[3],pt[1]),coor[1])
def main(w,h,n,pts):
    rec=[0,0,w,h]
    for x in range(n):
        nextrec(rec,pt[x]):
    return (rec[0]-rec[2])*(rec[1]-rec[3])

w,h,n=map(int,sys.stdin.readline().strip().split())
pts=[list(map(int,sys.stdin.readline().strip().split())) \
    for x in range(n)]

print(main(w,h,n,pts))
Problem p03997 (python)

Fixed submission:
import sys

def main(a,b,h):
    return (a+b)*h//2

a =int(sys.stdin.readline().strip())
b =int(sys.stdin.readline().strip())
h =int(sys.stdin.readline().strip())

print(main(a,b,h))

Buggy submission (verdict: Runtime Error):
import sys

def main(a,b,h):
    reuturn (a+b)*h//2

a =int(sys.stdin.readline().strip())
b =int(sys.stdin.readline().strip())
h =int(sys.stdin.readline().strip())

print(main(a,b,h))

Buggy submission (verdict: Runtime Error):
import sys

def main(a,b,h)
    reuturn (a+b)*h//2

a =int(sys.stdin.readline().strip())
b =int(sys.stdin.readline().strip())
h =int(sys.stdin.readline().strip())

print(main(a,b,h))

Buggy submission (verdict: Runtime Error):
import sys

def main(a,b,h)
    reuturn (a+b)*h//2

a =int(sys.stdin.readlin().strip())
b =int(sys.stdin.readlin().strip())
h =int(sys.stdin.readlin().strip())

print(main(a,b,h))
Problem p04014 (python)

Fixed submission:
import sys
import math

def divlist(n):
   sl=[]
   ll=[]
   for x in range(1,int(math.sqrt(n))+1):
       if n%x==0:
           sl.append(x)
           ll.append(n//x)
   ll.reverse()
   sl.extend(ll)
   return sl

def f(b,n):
    if n<b:
        return n
    else:
        return f(b,n//b)+(n%b)

def main(n,s):
    if n<s:
        return print(-1)
    elif n==s:
        return print(n+1)
    else:
        dl=divlist(n-s)
        for x in dl:
            if s==f(x+1,n):
                return print(x+1)
        return print(-1)

n=int(sys.stdin.readline().strip())
s=int(sys.stdin.readline().strip())

main(n,s)

Buggy submission (verdict: Runtime Error):
import sys
import math

def divlist(n):
   sl=[]
   ll=[]
   for x in range(1,int(math.sqrt(n))+1):
       if n%x==0:
           sl.append(x)
           ll.append(n//x)
   ll.reverse()
   sl.extend(ll)
   return sl

def f(b,n):
    if n<b:
        return n
    else:
        return f(b,n//b)+(n%b)

def main(n,s):
    if n<s:
        return print(-1)
    elif n==s:
        return prnit(n+1)
    else:
        dl=divlist(n-s)
        for x in dl:
            if s==f(x+1,n):
                return print(x+1)
        return print(-1)

n=int(sys.stdin.readline().strip())
s=int(sys.stdin.readline().strip())

main(n,s)

Buggy submission (verdict: Runtime Error):
import sys
import math

n=int(sys.stdin.readline().strip())
s=int(sys.stdin.readline().strip())

def divlist(n):
   sl=[]
   ll=[]
   for x in range(1,int(math.sqrt(n))+1):
       if n%x==0:
           sl.append(x)
           ll.append(n//x)
   ll.reverse()
   sl.extend(ll)
   return sl

def f(b,n):
    if n<b:
        return n
    else:
        return f(b,n//b)+(n%b)

if n<s:
    print(-1
elif n==s:
    print(n+1)
else:
    dl=divlist(n-s)
    for x in dl:
        if s==f(x+1,n):
            print(x+1)
            sys.exit()
    print(-1)
Problem p04030 (python)

Fixed submission:
s=input()
 
ans=''
for x in s:
  if x!='B':
    ans+=x
  else:
    if x!='':
      ans=ans[:-1]
print(ans)

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

ans=''
for x in s:
  if ans<>'':
    if x=='B'
      ans=ans[:-1]
      continue
  if x<>'B':
    ans+=x
print(ans)
Problem p04032 (python)

Fixed submission:
import sys
import string
 
alphabets=list(string.ascii_lowercase)
 
s=input()
 
l=len(s)
 
hm = lambda a,string: sum([x==a for x in string])
 
for x in range(l-1):
  if s[x]==s[x+1]:
    print('{} {}'.format(x+1, x+2))
    sys.exit()
 
 
for n in range(l-3):
  for a in alphabets:
    if hm(a,s[n:n+3])> 1:
      print('{} {}'.format(n+1,n+3))
      sys.exit()
print('-1 -1')

Buggy submission (verdict: Runtime Error):
import sys
import string
 
alphabets=list(string.ascii_lowercase)
 
s=input()
 
l=len(s)
 
hm = lambda a,string: sum([x==a for x in string])
 
for x in range(l-1):
  if s[x]==s[x+1]:
    print('{} {}'.format(x+1, x+2))
    sys.exit()
 
 
for n in range(l-3):
  for a in alphabets:
    if hm(a,s[n:n+3])> m//2:
      print('{} {}'.format(n+1,n+3))
      sys.exit()
print('-1 -1')

Buggy submission (verdict: Runtime Error):
import sys
import string

alphabets=list(string.ascii_lowercase)

s=input()

l=len(s)

hm = lambda a,string: sum([x==a for x in string])

for x in range(l-1):
  if s[x]==s[x+1]:
    print('{} {}'.format(x+1, x+2))
    sys.exit()


for n in range(l-m):
  for a in alphabets:
    if hm(a,s[n:n+3])> m//2:
      print('{} {}'.format(n+1,n+m))
      sys.exit()
print('-1 -1')

Buggy submission (verdict: Runtime Error):
import sys
import string

alphabets=list(string.ascii_lowercase)

s=input()

l=len(s)

hm = lambda a,string: sum([x==a for x in string])

for x in range(l-1):
  if s[x]==s[x+1]:
    print('{} {}'.format(x+1, x+2))
    sys.exit()

def func(r,s,n,m):
  if r==26:
    return print('-1 -1')
  else:
    if hm(alphabets[r],s[n:n+m])>m//2:
      print('{} {}'.format(r+1,n+m))
      sys.exit()
    return func(n+1,s,n,m)

for m in range(3,l,2):
  for n in range(l-m):
    func(0,s,n,m)

Buggy submission (verdict: Runtime Error):
import sys
import string

alphabets=list(string.ascii_lowercase)

s=input()

l=len(s)

hm = lambda a,string: sum([x==a for x in string])

for x in range(l-1):
  if s[x]==s[x+1]:
    print('{} {}'.format(x+1, x+2))
    sys.exit()

def func(r,s,n,m):
  if r==26:
    return print('-1 -1')
  else:
    if hm(alphabets[r],s[n:n+m])>m//2:
      print('{} {}'.format(n+1,n+m))
      sys.exit()
    return func(n+1,s,n,m)

for m in range(3,l,2):
  for n in range(l-m):
    func(0,s,n,m)
Problem p03478 (python)

Fixed submission:
n, a, b = map(int, raw_input().split())
ans = 0
for _ in range(n + 1):
    if a <= sum(map(int, list(str(_)))) <= b:
        ans += _
print ans

Buggy submission (verdict: Runtime Error):
n, a, b, ans = map(int, raw_input().split()), 0
for _ in range(n + 1):
    if a <= sum(map(int, list(str(i)))) <= b:
        ans += i
print ans
Problem p03730 (python)

Fixed submission:
from fractions import gcd
a, b, c = map(int, raw_input().split())
print ['NO', 'YES'][c % gcd(a, b) is 0]

Buggy submission (verdict: Runtime Error):
from fractions import gcd
a, b, c = map(int, raw_input().split())
print ['NO', 'YES'][c % gcd(a, b) ^ 1]
Problem p03759 (python)

Fixed submission:
a, b, c = map(int, raw_input().split())
print ['NO', 'YES'][b - a == c - b]

Buggy submission (verdict: Runtime Error):
s1 = raw_input()
s2 = raw_input()
ans = ''
for i in range(min(len(s1), len(s2))):
    ans += s1[i] + s2[i]
if len(s2) < len(s1):
    ans += s1[-1]
print ans
Problem p03773 (python)

Fixed submission:
print sum(map(int, raw_input().split())) % 24

Buggy submission (verdict: Runtime Error):
print (int(raw_input()) + int(raw_input())) % 24

Buggy submission (verdict: Runtime Error):
print (int(raw_input()) + int(raw_input()) % 24
Problem p03889 (python)

Fixed submission:
dict = { 'b' : 'd', 'd' : 'b', 'p' : 'q', 'q' : 'p' }
s = raw_input()
t = ''.join(map(lambda x : dict[x], list(s[::-1])))
print ['No', 'Yes'][s == t]

Buggy submission (verdict: Runtime Error):
dict = { 'b' : 'd', 'd' : 'b', 'p' : 'q', 'q' : 'p' }
s = raw_input()
t = ''.join(map(lambda x : dict[x], list(S[::-1])))
print ['No', 'Yes'][s == t]
Problem p03945 (python)

Fixed submission:
s, ans = raw_input(), 0
for i in range(len(s) - 1):
    if (len(set(s[i : i + 2])) == 2):
        ans += 1
print ans

Buggy submission (verdict: Runtime Error):
s, ans = raw_input(), 0
for i in range(len(s) - 1):
    if (len(set(s[i : i + 2))) == 2):
        ans += 1
print ans

Buggy submission (verdict: Runtime Error):
s, ans = raw_input(), 0
for i in range(len(s) - 1):
    if (len(set(s[i : i + 2))) == 2):
        ans += 1
print cnt

Buggy submission (verdict: Runtime Error):
s, ans = raw_input(), 0
for i in range(len(s) - 1):
    if (len(set(s[i : i + 2))) == 2):
        cnt += 1
print cnt
Problem p03970 (python)

Fixed submission:
s1 = 'CODEFESTIVAL2016'
s2 = raw_input()
ans = 0
for i in range(len(s1)):
    ans += [0, 1][s1[i] != s2[i]]
print ans

Buggy submission (verdict: Runtime Error):
s1 = 'CODEFESTIVAL2016'
print s2
ans = 0
for i in range(len(s1)):
    ans += [0, 1][s1[i] != s2[i]]
print ans
Problem p03975 (python)

Fixed submission:
a, b, c = map(int, input().split())
ans = 0
for i in range(a):
    n = int(input())
    if n < b or n >= c:
        ans += 1
print(ans)

Buggy submission (verdict: Runtime Error):
a, b, c = map(int, input().split())
ans = 0
for i in range(a):
    n = int(input())
    if n < b:
        ans += 1
print ans
Problem p04029 (python)

Fixed submission:
print sum(range(1, int(raw_input()) + 1))

Buggy submission (verdict: Runtime Error):
print sum(range(1, int(raw_input() + 1)))
Problem p04033 (python)

Fixed submission:
a, b = map(int, raw_input().split())
if a * b < 0:
    print 'Zero'
elif a + b < 0 and abs(a - b) & 1 == 0:
    print 'Negative'
else:
    print 'Positive'

Buggy submission (verdict: Runtime Error):
a, b = map(int, raw_input().split())
if a * b < 0:
    print 'Zero'
elif n + m < 0 and abs(a - b) & 1 == 0:
    print 'Negative'
else:
    print 'Positive'

Buggy submission (verdict: Runtime Error):
a, b = map(int, raw_input().split())
s = 1
for i in range(a, b + 1):
    s *= i
if s == 0:
    print 'Zero'
else:
    print ['Negative', 'Positive'][s > 0]
Problem p04044 (python)

Fixed submission:
n = int(raw_input().split()[0])
a = []
for i in range(n):
    a.append(raw_input())
a.sort()
ans = ''
for i in a:
    ans += i;
print ans

Buggy submission (verdict: Runtime Error):
n = int(raw_input())
s = ''
for i in range(n):
    s += raw_input()
s = sorted(s)
ans = ''
for i in s:
    ans += i
print ans
Problem p03417 (python)

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

if n == 1 and m == 1:
    print(1)
elif n == 1 and m > 1:
    print(m - 2)
elif n > 1 and m == 1:
    print(n - 2)
else:
    print((n-2)*(m-2))

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

# initialize the cards array. True if the card shows Back side. False if the card shows Top side
arr = [ [False] * m ] * n

for i in range(n):
    for j in range(m):
        for a in [-1, 0, 1]:
            for b in [-1, 0, 1]:
                if (i-b >=0 and j-a >= 0) and (i-b < n and j-a < m):
                    arr[i-b][j-a] = not arr[i-b][j-a]

print(sum(sum(l) for l in arr))

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

# initialize the cards array. True if the card shows Back side. False if the card shows Top side
arr = [ [False] * m ] * n

for i in range(n):
    for j in range(m):
        for a in [-1, 0, 1]:
            for b in [-1, 0, 1]:
                if (i-b >=0 and j-a >= 0) and (i-b < n and j-a < m):
                    arr[i-b][j-a] = not arr[i-b][j-a]

print(arr)
print(sum(sum(l) for l in arr))

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

# initialize the cards array. True means the card shows back side
arr = [ [False] * m ] * n

for i in range(n):
    for j in range(m):
        for a in [-1, 0, 1]:
            for b in [-1, 0, 1]:
                if i-b >=0 and j-a >= 0:
                    try:
                        arr[i-b][j-a] = not arr[i-b][j-a]
                    except IndexError:
                        pass
        print(i,j, arr)

print(sum(sum(l) for l in arr))
Problem p03486 (python)

Fixed submission:
from itertools import zip_longest

def twoAnagrams(s, t):
    s_str = ''.join(sorted(s))
    t_str = ''.join(sorted(t, reverse=True))

    if t_str.startswith(s_str):
        if len(s_str) < len(t_str):
            return True
        # this implies s and t is the same string
        else:
            return False

    for s_chr,t_chr in zip_longest(s_str, t_str):
        if s_chr is None:
            return True
        elif t_chr is None or t_chr < s_chr:
            return False
        elif s_chr < t_chr:
            return True


s = list(input())
t = list(input())

print('Yes' if twoAnagrams(s,t) else 'No')

Buggy submission (verdict: Runtime Error):
from itertools import zip_longest

def twoAnagrams(s, t):
    s_str = ''.join(sorted(s))
    t_str = ''.join(sorted(t, reverse=True))

    if t_str.startswith(s_str):
        if len(s_str) < len(t_str):
            return True
        # this implies s and t is the same string
        else:
            return False

    for s_chr,t_chr in zip_longest(s_str, t_str):
        if s_chr is None:
            return True
        elif t_chr is None or t_chr < s_chr:
            return False
        else s_chr < t_chr:
            return True


s = list(input())
t = list(input())

print('Yes' if twoAnagrams(s,t) else 'No')

Buggy submission (verdict: Runtime Error):
from itertools import zip_longest

def twoAnagrams(s, t):
    s_str = ''.join(sorted(s))
    t_str = ''.join(sorted(t, reverse=True))

    if t_str.startswith(s_str):
        if len(s_str) < len(t_str):
            return True
        # this implies s and t is the same string
        else:
            return False

    for s_chr,t_chr in zip_longest(s_str, t_str):
        if s_chr is None or s_chr < t_chr:
            return True
        elif t_chr is None or t_chr < s_chr:
            return False


s = list(input())
t = list(input())

print('Yes' if twoAnagrams(s,t) else 'No')
Problem p03501 (python)

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

print(a*n if b > a*n else b)

Buggy submission (verdict: Runtime Error):

n = int(input())
f = []
for _ in range(n):
    f.append(list(map(int, input().split())))
p = []
for _ in range(n):
    p.append(list(map(int, input().split())))

result = -100000000

# opening schedule for my shop.
# start from 1(only open Mon.AM) to 1023(open all day)
for b in range(1, 1<<10):

    profit = 0
    # compare with other shops
    for i in range(n):

        common_opening = 0
        # compare time
        for j in range(10):

            if 1&(b>>j) and f[i][j] == 1:
            
                common_opening += 1
        profit += p[i][common_opening]

    result = max(result, profit)

print(result)
Problem p03545 (python)

Fixed submission:
nums = [int(num) for num in input()]

target = 7

if sum(nums) == target:
    symbols = '+++'
elif nums[0] + nums[1] + nums[2] - nums[3] == target:
    symbols = '++-'
elif nums[0] + nums[1] - nums[2] + nums[3] == target:
    symbols = '+-+'
elif nums[0] + nums[1] - nums[2] - nums[3] == target:
    symbols = '+--'
elif nums[0] - nums[1] + nums[2] + nums[3] == target:
    symbols = '-++'
elif nums[0] - nums[1] + nums[2] - nums[3] == target:
    symbols = '-+-'
elif nums[0] - nums[1] - nums[2] + nums[3] == target:
    symbols = '--+'
elif nums[0] - nums[1] - nums[2] - nums[3] == target:
    symbols = '---'

result = ''
for i in range(len(symbols)):
    result += str(nums[i])
    result += symbols[i]
result += str(nums[-1])

print('{}=7'.format(result))

Buggy submission (verdict: Runtime Error):
nums = [int(num) for num in input()]

target = 7

if sum(nums) == target:
    symbols = '+++'
elif nums[0] + nums[1] + nums[2] - nums[3] == target:
    symbols = '++-'
elif nums[0] + nums[1] - nums[2] + nums[3] == target:
    symbols = '+-+'
elif nums[0] + nums[1] - nums[2] - nums[3] == target:
    symbols = '+--'
elif nums[0] - nums[1] + nums[2] + nums[3] == target:
    symbols = '-++'
elif nums[0] - nums[1] + nums[2] - nums[3] == target:
    symbols = '-+-'
elif nums[0] - nums[1] - nums[2] + nums[3] == target:
    symbols = '--+'
elif nums[0] - nums[1] - nums[2] - nums[3] == target:
    symbols = '---'

print(f'{nums[0]}{symbols[0]}{nums[1]}{symbols[1]}{nums[2]}{symbols[2]}{nums[3]}=7')
Problem p03407 (python)

Fixed submission:
s = input()
a, b, c = [int(x) for x in s.split(' ')]
if a+b < c:
    print('No')
else:
    print('Yes')

Buggy submission (verdict: Runtime Error):
s = input()
a, b, c = [int(x) for x in s.split(' ')]
if a+b < c:
    echo('No')
else:
    echo('Yes')

Buggy submission (verdict: Runtime Error):
s = input()
a, b, c = [int(x) for x in s.split(' ')]
if a+b < c:
    return 'No'
else:
    return 'Yes'

Buggy submission (verdict: Runtime Error):
a, b, c = input().split(' ')
if a+b < c:
    return 'No'
else:
    return 'Yes'
Problem p03407 (python)

Fixed submission:
a, b, c = map(int, raw_input().split())
print "Yes" if a + b >= c else "No"

Buggy submission (verdict: Runtime Error):
a, b, c = map(int, raw_input().split())
return "Yes" if a + b >= c else "No"
Problem p03543 (python)

Fixed submission:
n = input()
if n[0] == n[1] == n[2] or n[1] == n[2] == n[3]:
	print('Yes')
else:
	print('No')

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

if s[0] == s[1] == s[2] or s[1] == s[2] == s[3]
    print('Yes')
else:
    print('No')
Problem p03407 (python)

Fixed submission:
nums = list(map(int, input().split())) 

           
if nums[0]+nums[1] >= nums[2]:
    print('Yes')
else:
    print('No')

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

if A+B >= C:
    print('Yes')
else:
    print('No')

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

if A+B >= C:
    print('Yes')
else:
    print('No')
Problem p04045 (python)

Fixed submission:
li_1 = list(map(int,input().split()))
N = li_1[0]
K = li_1[1]

D = list(map(int,input().split()))


minvalue=N
temp=0

for i in range(10*N):
    i=i+N
    numtemp=i
    if numtemp>=10000:
        num_4=int(i/10000)
        i=i-10000*num_4
    else:
        num_4=10
        
    if numtemp>=1000:
        num_3=int(i/1000)
        i=i-1000*num_3
    else:
        num_3=10
        
    if numtemp>=100:
        num_2=int(i/100)
        i=i-100*num_2
    else:
        num_2=10
        
    if numtemp>=10:
        num_1=int(i/10)
        i=i-10*num_1
    else:
        num_1=10
        
    num_0=i
    
    for j in range(K):
        if (num_0!=D[j])and(num_1!=D[j])and(num_2!=D[j])and(num_3!=D[j])and(num_4!=D[j]):
            temp+=1
            
    if temp==K:
        num=numtemp
        break
    
    temp=0

print(num)

Buggy submission (verdict: Runtime Error):
li_1 = list(map(int,input().split()))
N = li_1[0]
K = li_1[1]

D = list(map(int,input().split()))


minvalue=N
temp=0

for i in range(10*N):
    i=i+N
    numtemp=i
    num_4=int(i/10000)
    i=i-10000*num_4
    num_3=int(i/1000)
    i=i-1000*num_3
    num_2=int(i/100)
    i=i-100*num_2
    num_1=int(i/10)
    i=i-10*num_1
    num_0=i
    
    for j in range(K):
        if (num_0!=D[j])and(num_1!=D[j])and(num_2!=D[j])and(num_3!=D[j])and(num_4!=D[j]):
            temp+=1
            
    if temp==K:
        num=numtemp
        break
    
    temp=0

print(num)

Buggy submission (verdict: Runtime Error):
li_1 = list(map(int,input().split()))
N = li_1[0]
K = li_1[1]

D = list(map(int,input().split()))


minvalue=N
temp=0

for i in range(10*(N+1)):
    i=i+N
    numtemp=i
    num_4=int(i/10000)
    i=i-10000*num_4
    num_3=int(i/1000)
    i=i-1000*num_3
    num_2=int(i/100)
    i=i-100*num_2
    num_1=int(i/10)
    i=i-10*num_1
    num_0=i
    
    for j in range(K):
        if (num_0!=D[j])and(num_1!=D[j])and(num_2!=D[j])and(num_3!=D[j]):
            if j==K-1:
                temp=1
        else:
            break
    if temp==1:
        num=numtemp
        break

print(num)

Buggy submission (verdict: Runtime Error):

li_1 = list(map(int,input().split()))
N = li_1[0]
K = li_1[1]

D = list(map(int,input().split()))


minvalue=N
temp=0

for i in range(N+1):
    i=i+N
    numtemp=i
    num_4=int(i/10000)
    i=i-10000*num_4
    num_3=int(i/1000)
    i=i-1000*num_3
    num_2=int(i/100)
    i=i-100*num_2
    num_1=int(i/10)
    i=i-10*num_1
    num_0=i
    
    for j in range(K):
        if (num_0!=D[j])and(num_1!=D[j])and(num_2!=D[j])and(num_3!=D[j]):
            if j==K-1:
                temp=1
        else:
            break
    if temp==1:
        num=numtemp
        break

print(num)
Problem p03563 (python)

Fixed submission:
R=int(input())
G=int(input())
print(2*G-R)

Buggy submission (verdict: Runtime Error):
R=input()
G=input()
print(2*G-R)

Buggy submission (verdict: Runtime Error):
R=input()
G=input()
if R<G:
  print(2*G-R)
elif R>G:
  print(-1*(2*G-R))
Problem p03577 (python)

Fixed submission:
s=input()
print(s[:-8])

Buggy submission (verdict: Runtime Error):
s=input()
print(s[i]-s[-7])
Problem p03587 (python)

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

Buggy submission (verdict: Runtime Error):
s=input()
print (s.count(1))
Problem p03657 (python)

Fixed submission:
a,b=map(int,input().split())
c=a + b
 
if  a%3==0 or b%3==0 or c%3==0: print("Possible")
else: print("Impossible")

Buggy submission (verdict: Runtime Error):
A=int(input()) % 3
B=int(input()) % 3
C=A + B
 
if  A==0 or B==0 or C==0: print("Possible")
else: print("Impossible")

Buggy submission (verdict: Runtime Error):
a=int(input())
b=int(input())
c=a+b
 
if  a%3==0 or b%3==0 or c%3==0: print("Possible")
else: print("Impossible")

Buggy submission (verdict: Runtime Error):
a=int(input())
b=int(input())
c=a + b
 
if  a%3==0 or b%3==0 or c%3==0: print("Possible")
else: print("Impossible")

Buggy submission (verdict: Runtime Error):
A=int(input())
B=int(input())
C=A + B
 
if  A%3==0 or B%3==0 or C%3==0: print("Possible")
else: print("Impossible")

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

if  A % 3 == 0 or B % 3 == 0 or C % 3 == 0:
 print("Possible")
else:
 print("Impossible")

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

if  A % 3 == 0 : print("Possible")
else: print("Impossible")
if B % 3 == 0 : print("Possible")
else: print("Impossible")
if C % 3 == 0 : print("Possible")
else: print("Impossible")

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

if  A % 3 == 0 : print("Possible")
else: print("Impossible")
if B % 3 == 0 : print("Possible")
else: print("Impossible")
if A+B % 3 == 0 : print("Possible")
else: print("Impossible")
Problem p03407 (python)

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

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

Buggy submission (verdict: Runtime Error):
a = int(input("coinA:"))
b = int(input("coinB:"))
c = int(input("priceC:"))

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