qyliang/CodeNanoFix huggingface dataset:
Buggy code:
a, b = map(int, input().split())
print(max(0, a - 2 * b)

Fixed code:
a, b  = map(int, input().split())
print(max(0, a-2*b))
Buggy code:
A, B = list(map(int, input().split()))
if A<2*B:
  print(O)
else:
  print(A-2*B)

Fixed code:
A, B = list(map(int,input().split()))
if A<2*B:
  print(0)
else:
  print(A-2*B)
Buggy code:
A, B = map(int, input().split())
ans = 0
tmp = 0
if A > (2 * B):
    tmp = A - (2 * B)
else:
    tmp = B - A

if 0 < tmp:
    ans = tmp
print(ans)

Fixed code:
A, B = map(int, input().split())
ans = 0
tmp = A - (2 * B)

if 0 < tmp:
    ans = tmp
print(ans)
Buggy code:
A,B= map(int,input().split())

if A >= B*2:
  print(A-2B)
else:
  print(0)

Fixed code:
A,B = map(int, input().split())

if A > B * 2:
    print(A-B*2)
else:
    print(0)
Buggy code:
A, B = map(int,input())

C = A- 2*B

if C >=0:
  print(C)
else:
  print(0)

Fixed code:
A, B = map(int,input().split())
 
C = A- 2*B
 
if C >=0:
  print(C)
else:
  print(0)
Buggy code:
a, b = input().split()
print(max(0, int(b) - 2*int(a))

Fixed code:
a, b = input().split()
print(max(0, int(a) - 2*int(b)))
Buggy code:
a,b=map(int,input().split())
if a>b*2:
  print(b*2-a)
else:
  print(0)

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

ans = a-b*2
print(ans if ans > 0 else 0)
Buggy code:
a,b=map(int,input().split())
if a<b*2:
  print(b*2-a)
else:
  print(0)

Fixed code:
a,b=map(int,input().split())
if 0>a-(2*b):
    print(0)
else:
    print(a-(2*b))
Buggy code:
A,B = map(int,input().split)
if A - B * 2 > 0:
    print(A - B * 2)
else:
    print(0)

Fixed code:
A, B = map(int, input().split())
r = A - 2*B
print(r if r > 0 else 0)
Buggy code:
a, b = [int(i) for i in input().split()]
print(max(0, a - 2 * b)

Fixed code:
a, b = [int(i) for i in input().split()]
print(max(0, a - 2 * b))
Buggy code:
a, b = map(int, input().split())
if a<=b*2:
    print(0)
else:
    print(a-b*2)a, b = map(int, input().split())
if a<=b*2:
    print(0)
else:
    print(a-b*2)

Fixed code:
a, b = map(int, input().split())
if a<=b*2:
    print(0)
else:
    print(a-b*2)
Buggy code:
a,b = [int(j) for j in input().split()]
print(max(a-2*b, 0)

Fixed code:
a,b = [int(j) for j in input().split()]
print(max(a-2*b, 0))
Buggy code:
A,B = map(int,input().split())
if A-2*B < 0:
  print(0)
else:
  print(A-2*b)
  

Fixed code:
A,B = map(int,input().split())
if A-2*B < 0:
  print(0)
else:
  print(A-2*B)
Buggy code:
A,B = [int(c) for c in input().strip().split('')]
if 2*B>A:
  print(0)
else:
  print(A-2*B)

Fixed code:
A,B = [int(c) for c in input().strip().split(' ')]
if A>2*B:
    print(A-2*B)
else:
    print(0)
Buggy code:
A,B=map(int,input().split())
if A<=2*B:
  print(0)
else A>2*B
  print(A-(2*B))

Fixed code:
A, B = map(int, input().split())

ans = A - B*2

if ans < 0:
  print(0)
else:
  print(ans)
Buggy code:
a, b = map(int, input().split())
ans = a % (b * 2)

if ans <= 0:
    ans = 0

print(ans)


Fixed code:
a, b = map(int, input().split())
ans = a - (b * 2)

if ans <= 0:
    ans = 0

print(ans)
Buggy code:
a,b = map(int,input(),split())

if a <= b*2:
  print(0)
else:
  print(a-b*2)

Fixed code:
a,b = map(int,input().split())
 
if a <= b*2:
  print(0)
else:
  print(a-b*2)
Buggy code:
b, a=map(int, input().split())
if b>=(2*a):
  print(0)
else:
  print(b-(2*a))

Fixed code:
a,b = map(int,input().split())
if a>=2*b:
    print(a-2*b)
else:
    print(0)
Buggy code:
a = map(int, input().split())
b = a[0] - 2*a[1]
if b >= 0:
  print(b)
else:
  print(0)


Fixed code:
a = list(map(int, input().split()))
b = a[0] - 2*a[1]
if b >= 0:
  print(b)
else:
  print(0)
Buggy code:
x,y = map(int,input().split())
ans = x - y*2
if x < 0:
  print(0)
else:
  print(ans)

Fixed code:
x,y = map(int,input().split())
ans = x - y*2
if ans < 0:
  print(0)
else:
  print(ans)
Buggy code:
a,b = map(int,input().split())
c = 2*b
d = a-c
if a > c:
print(d)
elif a <= c:
print(0)

Fixed code:
a,b = map(int,input().split())
c = 2*b
d = a-c
if d > 0:
 print(d)
elif d <= 0:
 print(0)
Buggy code:
a, b = map(int, input(),split())

print(max(0, a-2*b))

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

print(max(0,a-2*b))
Buggy code:
a,b=map(int,input().split())
if a>2*b:
print(a-2*b)
else if:
print(0)

Fixed code:
a, b = map(int, input().split())
if(b*2 >= a):
    print("0")
else:
    print(str(a-b*2))
Buggy code:
a,b = input().split()
print(max(0,a-2*b))

Fixed code:
a,b = input().split()
a,b = int(a),int(b)
print(max(a-2*b,0))
Buggy code:
a,b= map(int,input().split(" "))
c=a -2＊b
if c>0:
  print(c)
else:
  print(0)

         

Fixed code:
a,b= map(int,input().split(" "))
c=a -2*b
if c>0:
  print(c)
else:
  print(0)
Buggy code:
a,b = map(input().split(' '))
print(max(a-2*b,0))

Fixed code:
a,b = map(int,input().split(' '))
print(max(a-2*b,0))
Buggy code:
A, B = map(int, input().split())

if A <= 2 * B:
  print(0)
  
else:
  print(2*B - A)

Fixed code:
A, B = map(int, input().split())
if A-2*B < 0:
    print(0)
else:
    print(A-2*B)
Buggy code:
a,b=map(int,input().split())
print(max(0,a-2*b)

Fixed code:
a, b = map(int, input().split())
print(max(0, a-(2*b)))
Buggy code:
A,B=map(int,input().split())
if A-2*B>=0:
  print(A-2B)
else:
  print('0')

Fixed code:
A,B=map(int,input().split())
if A-2*B>=0:
  print(A-2*B)
else:
  print(0)
Buggy code:
a,b=map(int,input().split())
if (b*2)>=a:
  print(a-(b*2))
else:
  print("0")
  

Fixed code:
a,b=map(int,input().split())
if (b*2)<=a:
  print(a-(b*2))
else:
  print("0")
Buggy code:
a,b=input().split()
a=int(a)
b=int(b)
c=b-2*a
if c<=0:
    print(0)
else:
    print(c)

Fixed code:
a,b=input().split()
a=int(a)
b=int(b)
c=a-2*b
if c<=0:
    print(0)
else:
    print(c)
Buggy code:
A,B = map(int, input().split())
#B = int(input())

if A <= 2 * B:
  print(0)
else:
  print(A-

Fixed code:
A, B = map(int, input().split())

if A - 2*B <0:
  ans = 0
else:
  ans = A - 2*B
  
print(ans)
Buggy code:
A,B=map(int,input().split())
n=A-(B*2)
if n>=0:
    print(n)
else:
    print(o)

Fixed code:
A,B=map(int,input().split())
n=A-(B*2)
if n>=0:
    print(n)
else:
    print(0)
Buggy code:
ABInput = str(input())
 
AB = ABInput.split(" ")
 
A = AB[0]
B = AB[1]

TotalCartain = B * 2

if TotalCartain > A or TotalCartain = A:
  print (0)
else:
  print (A-TotalCartain)

Fixed code:
ABInput = str(input())
 
AB = ABInput.split(" ")
 
A = int(AB[0])
B = int(AB[1])
 
TotalCartain = B * 2
 
if TotalCartain > A or TotalCartain == A:
  print (0)
else:
  print (A-TotalCartain)
Buggy code:
w ,k = map(int, input().split())
x = w - (k*2)
if 0 <= x:
  print(x)
 else:
  print(0)

Fixed code:
w, k = map(int, input().split())
x = w - (k*2)
if 0 <= x:
    print(x)
else:
    print(0)
Buggy code:
a,b = map(int, input().split())

if (b*2-a)>0:
  print(int(b*2-a))
else:
  print(0)

Fixed code:
a,b = map(int,input().split())
if b*2<a:
  print(a-b*2)
else:
  print(0)
Buggy code:
a,b=map(int,input().split())
#n,k=map(int,input().split())
#H=list(map(int,input().split()))
print(max(a-2*b),0)

Fixed code:
#n=int(input())
a,b=map(int,input().split())
#n,k=map(int,input().split())
#H=list(map(int,input().split()))
c=a-2*b
print(max(c,0))
Buggy code:
A, B = [int(i) for i in input().split())]
ret = A - B*2
print(ret if ret > 0 else 0)


Fixed code:
A, B = [int(i) for i in input().split()]
ret = A - B*2
print(ret if ret > 0 else 0)
Buggy code:
A,B=int(int,input().split())
m=A-2*B
if m<0:
  print(0)
else:
  print(m)

Fixed code:
A,B=map(int,input().split())
m=A-2*B
if m<0:
  print(0)
else:
  print(m)
Buggy code:
a, b = map(int, input().split())
print(max(a - 2 * b, 0)

Fixed code:
a,b=map(int,input().split())
print(max(0,(a-b*2)))
Buggy code:
# print(input().split(" "))
a,b=map(int, input().split())
# print("a:", a, "b:", b)
answer=a-2*b
# print(answer)
if(answer < 0):
    print(0)
else:answer

Fixed code:
# print(input().split(" "))
a,b=map(int, input().split())
# print("a:", a, "b:", b)
answer=a-2*b
# print(answer)
if(answer < 0):
    print(0)
else:
    print(answer)
Buggy code:
a,b=map(int,input().split())
B=b*2
if a<B:
  print(a-B)
else:
  print('0')

Fixed code:
a,b=map(int,input().split())
B=b*2
if a>B:
  print(a-B)
else:
  print('0')
Buggy code:
a, b = map(int, input().split())
if b <= a or b*2>=a:
    print(0)
else:
    print(a-b*2)

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

b = b*2

if a > b:
  print(a-b)
else:
  print(0)
Buggy code:
a,b = map(int, input().split())

if b*2 > a:
    print(0)
else:
    print(b*2 - a)

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

if a <= 2*b:
    print(0)
else:
    print(a - 2*b)
Buggy code:
 n, k = list(map( int , input().split()))
 print( max( 0 , n - 2*k))

Fixed code:
n, k = list(map( int , input().split()))
print( max( 0 , n - 2*k))
Buggy code:
a,b = map(int, input(3 ).split())

if b*2 > a:
    print(0)
else:
    print(b*2 - a)

Fixed code:
a, b = map(int, input().split())
x = a - 2 * b
if x > 0:
    print(x)
else:
    print(0)
Buggy code:
import sys

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

    if(A<=B*B):
        print('0')

    else:
        print(A-B*B)

main()

Fixed code:
import sys

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

    if(A<=2*B):
        print('0')

    else:
        print(A-2*B)

main()
Buggy code:
,b=list(map(int,input().split()))
s=a-2*b
if s<=0:
    print(0)
else:
    print(s)



Fixed code:
a,b=list(map(int,input().split()))
s=a-2*b
if s<=0:
    print(0)
else:
    print(s)
Buggy code:
a,b=list(map(int,input().split()))
if a<=b*2:
  print 0
else:
  print a-b*2

Fixed code:
a,b=list(map(int,input().split()))
if a<=b*2:
  print(0)
else:
  print(a-b*2)
Buggy code:
A, B = map(int, input().split())if(A-B*2>0):print(A-B*2)else:print(0)


Fixed code:
A, B = map(int, input().split(" "))

length = A - 2 * B
if length >= 0:
    print(length)
else:
    print(0)
Buggy code:
a,b = map(int,int().split())
print(0 if b*2>=a else a-b*2)

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

print(0 if b*2>=a else a-b*2)
Buggy code:
A, B = map(int, input().split())

value = A - B * 2
if value >= 0:
  return value
else:
  return 0

Fixed code:
A, B = map(int, input().split())
 
value = A - B * 2
if value >= 0:
  print(value)
else:
  print(0)
Buggy code:
A, B = map(int, input().split())

if 2 * B < A:
  answer = 2 * B - A
  print(answer)
else:
  print(0)

Fixed code:
A, B = map(int, input().split())

if 2 * B < A:
  answer = A - 2 * B
  print(answer)
else:
  print(0)
Buggy code:
a,b =(int(x) for x in input().split())
c=2*a-b
if c>=0:
  print(c)
else:
  print(0)

Fixed code:
a,b =(int(x) for x in input().split())
c=a-b*2
if c>=0:
  print(c)
else:
  print(0)
Buggy code:
a,b = map(int,input().split())
if a - (b*2) > 0:
  print(a - (b*2))
print(0)

Fixed code:
a,b = map(int,input().split())
if a - (b*2) > 0:
  print(a - (b*2))
else:
  print(0)
Buggy code:
a, b = map(int, input().split())

horizontal_length = b * 2

uncovered_part = a - horizontal_length

if uncovered_part < 0:
  uncovered_part = 0
  
print str(uncovered_part)
  

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

horizontal_length = b * 2

uncovered_part = a - horizontal_length

if uncovered_part < 0:
  uncovered_part = 0
  
print(str(uncovered_part))
Buggy code:
a,b = map(int, input().split())
print(max(0, 2*b-a))

Fixed code:
a, b = map(int, input().split())
print(max(0, a - 2 * b))
Buggy code:
a,b=map(int,input().split())
c = b*2 - a
if c > 0:
    print(0)
else:
    print(c)

Fixed code:
a,b=map(int,input().split())
if (a-2*b) > 0:
  print(a-2*b)
else:
  print(0)
Buggy code:
a,b = map(int,input().split())
print(max(0,b-a*2))

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

print(max(0, a - b*2))
Buggy code:
A, B = map(int, input())
C = A - B*2

if C >= 0:
  print(C)
else:
  print(0)

Fixed code:
A, B = map(int, input().split())
C = A - B*2

if C >= 0:
  print(C)
else:
  print(0)
Buggy code:
a.b = int(input().split())

if a <= b*2:
  print("0")
else:
  print(a-b*2)

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

if a <= b*2:
  print("0")
else:
  print(a-b*2)
Buggy code:
a,b=map(int,input().split())
if a>2*b:
  print(a-2b)
else:
  print(0)

Fixed code:
a,b=map(int,input().split())
if a-2*b>0:
  print(a-2*b)
else:
  print("0")
Buggy code:
a, b = map(int, input().split())
c = b * 2 - a
print(c if 0 <= c else 0)


Fixed code:
a, b = map(int, input().split())
c = a - b * 2
print(c if 0 <= c else 0)
Buggy code:
a,b=[int(a)for a in input().split()]

c=b+b
if(a-c!=0):
    print(a-c)
else:
    print(0)

#print(type(c))

Fixed code:
a,b=[int(a)for a in input().split()]

c=b+b
if(a-c!=0)and(a-c>=0):
    print(a-c)
else:
    print(0)

#print(type(c))
Buggy code:
a,b=map(int,input().split())
if a-2*b>=0:
  print(a-2*b)
else a-2*b<0:
  print(0)


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

if a <= b * 2:
  answer = 0
else:
  answer = a - (b * 2)
  
print(answer)
Buggy code:
a,b=map(int,input(),split())
if a-2*b>=0:
  print(a-2*b)
else a-2*b<0:
  print(0)


Fixed code:
a,b=map(int,input().split())
if b*2>=a:
  print(0)
else:
  print(a-b*2)
Buggy code:
a, b = input().split()

if a > b * 2:
  ret = a - b * 2
else:
  ret = 0
  
print(ret)



Fixed code:
a, b = map(int, input().split())
 
if a > b * 2:
  ret = a - b * 2
else:
  ret = 0
  
print(ret)
Buggy code:
x = input().split()

a = x[0]
b = x[1]

if a > b * 2:
  ret = a - b * 2
else:
  ret = 0
  
print(ret)

Fixed code:
x = input().split()
 
a = int(x[0])
b = int(x[1])
 
if a > b * 2:
  ret = a - b * 2
else:
  ret = 0
  
print(ret)
Buggy code:
# https://atcoder.jp/contests/abc143/tasks/abc143_a
# -*- coding: utf-8 -*-

stu_bangou = list(map(int, input().strip().split()))

print(stu_bangou[0] - (stu_bangou[1] * 2))# https://atcoder.jp/contests/abc143/tasks/abc143_a
# -*- coding: utf-8 -*-

stu_bangou = list(map(int, input().strip().split()))

if stu_bangou[0] < (stu_bangou[1] * 2):
    print(0)
else:
    print(stu_bangou[0] - (stu_bangou[1] * 2))


Fixed code:
# https://atcoder.jp/contests/abc143/tasks/abc143_a
# -*- coding: utf-8 -*-

stu_bangou = list(map(int, input().strip().split()))

if stu_bangou[0] < (stu_bangou[1] * 2):
    print(0)
else:
    print(stu_bangou[0] - (stu_bangou[1] * 2))
Buggy code:
A,B = map(int,input().split())

ans = A-B*2

if(x>=0):
  print(ans)
else:
  print("0")

Fixed code:
A,B = map(int,input().split())

ans = A-B*2

if(ans>=0):
  print(ans)
else:
  print("0")
Buggy code:
a, b= map(int, input().split())

if a-b*2<=0:
  print(0)
 else:
  print(a-b*2)

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

ans = a - b*2

if ans < 0:
	ans = 0
print(ans)
Buggy code:
a,b = map(int, input().split())
ans = a - b + b
if ans <= 0:
  print(0)
else:
  print(ans)

Fixed code:
a,b = map(int, input().split())
ans = a - b - b
if ans <= 0:
  print(0)
else:
  print(ans)
Buggy code:
a,b=map(int,input().split())
if a<b*2:
  print(a-b*2)
else:
  print(0)

Fixed code:
a, b = map(int, input().split())
if a - 2 * b <= 0:
    print(0)
else:
    print(a - 2 * b)
Buggy code:
# coding: utf-8
a, b = map(int, input().split())
ans = a - b * 2
if ans < 0:
    ams = 0
print(ans)

Fixed code:
# coding: utf-8
a, b = map(int, input().split())
ans = a - b * 2
if ans < 0:
    ans = 0
print(ans)
Buggy code:
a, b = input()
num_a = int(a)
num_b = int(b)
dif = num_a - num_b*2
if dif >= 0:
  print(dif)
else:
  print(0)

Fixed code:
a, b = input().split()
num_a = int(a)
num_b = int(b)
dif = num_a - num_b*2
if dif >= 0:
  print(dif)
else:
  print(0)
Buggy code:
a, b = map(int, input().split())
result = a - (b*2)
if a > 0:
    print(result)
else:
    print(0)

Fixed code:
a, b = map(int, input().split())
result = a - (b*2)
if result > 0:
    print(result)
else:
    print(0)
Buggy code:
A, B = map(int, input().split())
 print(A-2*B) if A > 2*B else print("0")

Fixed code:
A, B = map(int, input().split())
print(A-2*B) if A > 2*B else print(0)
Buggy code:
def main():
A, B = map(int, input().split())
 print(A-2*B) if A > 2*B else print("0")
  
mail()

Fixed code:
def main():
 A, B = map(int, input().split())
 print(A-2*B) if A > 2*B else print(0)
  
main()
Buggy code:
a,b = map(lambda x : int(x), input().split())
print(max(a - b * 2),0)

Fixed code:
a,b=map(lambda x:int(x),input().split())
print(max([0,a-b*2]))
Buggy code:
A,B = map(int,input().split())

if A>B*2:
    print(A-B*2)
if A=B*2:
    print(0)
if A<B*2:
    print(0)

Fixed code:
A,B = map(int,input().split())

if A>B*2:
    print(A-B*2)

else:
    print(0)
Buggy code:
lis = [ int(i) for i in input().split]
a = lis[0]
b = lis[1]
if b*2 > a:
  print(0)
else:
  print(a - b*2)

Fixed code:
lis = [ int(i) for i in input().split()]
a = lis[0]
b = lis[1]
if b*2 > a:
  print(0)
else:
  print(a - b*2)
Buggy code:
a, b = map(int, input().split())

print(max(0, a-2*b)
      

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

print(max(0, a-2*b))
Buggy code:
a, b = map(int,input().split())
if a >= 2*b:
  print(0)
else:
  print(a-2*b)

Fixed code:
a, b = map(int,input().split())
if a <= 2*b:
  print(0)
else:
  print(a-2*b)
Buggy code:
0from heapq import heappush, heappop
from collections import deque,defaultdict,Counter
import itertools
from itertools import permutations,combinations
import sys
import bisect
import string
#import math
#import time
#import random  # randome is not available at Codeforces
def I():
    return int(input())
def MI():
    return map(int,input().split())
def LI():
    return [int(i) for i in input().split()]
def LI_():
    return [int(i)-1 for i in input().split()]
def StoI():
    return [ord(i)-97 for i in input()]
def show(*inp,end='\n'):
    if show_flg:
        print(*inp,end=end)
YN=['Yes','No']
mo=10**9+7
inf=float('inf')
#eps=10**(-10)
#ts=time.time()
#sys.setrecursionlimit(10**6)
input=lambda: sys.stdin.readline().rstrip()

show_flg=False
show_flg=True

a,b=MI()
print(max(0,a-2*b))

Fixed code:
from heapq import heappush, heappop
from collections import deque,defaultdict,Counter
import itertools
from itertools import permutations,combinations
import sys
import bisect
import string
#import math
#import time
#import random  # randome is not available at Codeforces
def I():
    return int(input())
def MI():
    return map(int,input().split())
def LI():
    return [int(i) for i in input().split()]
def LI_():
    return [int(i)-1 for i in input().split()]
def StoI():
    return [ord(i)-97 for i in input()]
def show(*inp,end='\n'):
    if show_flg:
        print(*inp,end=end)
YN=['Yes','No']
mo=10**9+7
inf=float('inf')
#eps=10**(-10)
#ts=time.time()
#sys.setrecursionlimit(10**6)
input=lambda: sys.stdin.readline().rstrip()

show_flg=False
show_flg=True

a,b=MI()
print(max(0,a-2*b))
Buggy code:
import sys; readline = sys.stdin.readline
from collections import deque


A, B = map(int, readline().split())
print(max(A - 2 * B))

Fixed code:
import sys; readline = sys.stdin.readline
from collections import deque


A, B = map(int, readline().split())
print(max(0, A - 2 * B))
Buggy code:
from sys import stdin,stdout
def INPUT():return list(int(i) for i in stdin.readline().split())
import math
def inp():return stdin.readline()
def out(x):return stdout.write(x)
import math as M
MOD=10**9+7
import sys
#####################################
a,b=INPUT()
if a>=2*b:
    print(a-2b)
else:
    print(0)


Fixed code:
from sys import stdin,stdout
def INPUT():return list(int(i) for i in stdin.readline().split())
import math
def inp():return stdin.readline()
def out(x):return stdout.write(x)
import math as M
MOD=10**9+7
import sys
#####################################
a,b=INPUT()
if a>=2*b:
    print(a-2*b)
else:
    print(0)
Buggy code:
A, B = int(input().split())
if A - 2 * B <= 0:
  print(0)
else:
  print(A-2*B)

Fixed code:
A, B = map(int, input().split())
if A - 2 * B <=0:
  print(0)
else:
  print(A - 2 * B)
Buggy code:
#!usr/bin/env python3
from collections import defaultdict,deque
from heapq import heappush, heappop
import sys
import math
import bisect
import random
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def I(): return int(sys.stdin.readline())
def LS():return [list(x) for x in sys.stdin.readline().split()]
def S():
    res = list(sys.stdin.readline())
    if res[-1] == "\n":
        return res[:-1]
    return res
def IR(n):
    return [I() for i in range(n)]
def LIR(n):
    return [LI() for i in range(n)]
def SR(n):
    return [S() for i in range(n)]
def LSR(n):
    return [LS() for i in range(n)]

sys.setrecursionlimit(1000000)
mod = 1000000007

def solve():
    a,b = LI()
    print(max(0,b-2*a))
    return

#Solve
if __name__ == "__main__":
    solve()


Fixed code:
#!usr/bin/env python3
from collections import defaultdict,deque
from heapq import heappush, heappop
import sys
import math
import bisect
import random
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def I(): return int(sys.stdin.readline())
def LS():return [list(x) for x in sys.stdin.readline().split()]
def S():
    res = list(sys.stdin.readline())
    if res[-1] == "\n":
        return res[:-1]
    return res
def IR(n):
    return [I() for i in range(n)]
def LIR(n):
    return [LI() for i in range(n)]
def SR(n):
    return [S() for i in range(n)]
def LSR(n):
    return [LS() for i in range(n)]

sys.setrecursionlimit(1000000)
mod = 1000000007

def solve():
    a,b = LI()
    print(max(0,a-2*b))
    return

#Solve
if __name__ == "__main__":
    solve()
Buggy code:
ns = input().split(" ")
a = int(ns[0])
b = int(ns[1])
if a - 2 * b >> 0:
  print(a - 2 * b)
else:
  print(0)


Fixed code:
ns = input().split(" ")
a = int(ns[0])
b = int(ns[1])
if (a - 2 * b) > 0:
  print(a - 2 * b)
else:
  print(0)
Buggy code:
import fileinput

def process(A, B):
	if A =< B*2:
      return 0
    else:
      return A - B*2

for line in fileinput.input():
    print(process(map(int, line.split()))

Fixed code:
import fileinput

def process(A, B):
    if A <= B*2:
        return 0
    else:
        return A - B*2

for line in fileinput.input():
    print(process(*map(int, line.split())))
Buggy code:
a,b = (int, input().split())
print( max(0, a-b*2) )

Fixed code:
a,b = map(int, input().split())
print(max(0, a-b*2))
Buggy code:
a,b = map(int,input().split())

if a>=2*b:
  print(0)
else:
  print(a-2*b)

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

if a > 2*b:
    print(a-2*b)

else:
    print(0)
Buggy code:
a,b=map(int,input().split())

if a<2b:
  print("0")
else:
  print(a-2*b)

Fixed code:
a,b=map(int,input().split())
 
if a<2*b:
  print("0")
else:
  print(a-2*b)
Buggy code:
a, b = map(int, input().split())
print(max(0,a-(b*2))

Fixed code:
a, b = map(int, input().split())
print(max(0,a-(b*2)))
Buggy code:
x, y = int(input().split())
if x - 2*y >= 0:
  print(x-2*y)
else:
  print(0)

Fixed code:
x, y = map(int, input().split())
if x - 2*y >= 0:
  print(x-2*y)
else:
  print(0)
Buggy code:
import sys

if sys.platform =='ios':
    sys.stdin=open('input_file.txt')
    
a,b=map(int(input().split()))

print(max(0,a-2*b))

Fixed code:
import sys

if sys.platform =='ios':
    sys.stdin=open('input_file.txt')
    
a,b=map(int,input().split())

print(max(0,a-2*b))
Buggy code:
s=list(map(int,input().split()))
if s[1]-2*s[2]<0:
  print(0)
else:
  print(s[1]-2*s[2])

Fixed code:
s=list(map(int,input().split()))
if s[0]-2*s[1]<0:
  print(0)
else:
  print(s[0]-2*s[1])
Buggy code:
A,B=map(int, input().split())
print(0 if B<A*2 else B-A*2)

Fixed code:
A,B = map(int, input().split())

if A <= B*2:
    print(0)
else:
    print(A-B*2)
Buggy code:
a,b=map(int,input().split())
if a > b*2:
    print(0)
else:
    print(a-b*2)

Fixed code:
a, b = map(int, input().split())
if a <= 2 * b:
    print(0)
else:
    print(a - 2 * b)
Buggy code:
A, B = map(int,input().split())
print(max(0, a - B * 2))

Fixed code:
A, B = map(int,input().split())
print(max(0, A - B * 2))
Buggy code:
A = list(map(int, input().split())) 
return max(0,A[0]-2*A[1])

Fixed code:
A = list(map(int, input().split())) 
print(max(0,A[0]-2*A[1]))
Buggy code:
a.b = map(int,input().split())
if(a > b * 2):
    print(a-b * 2)
else:
    print(0)

Fixed code:
a,b=map(int,input().split())
if a >= 2*b:
  print(a-2*b)
else:
  print(0)
Buggy code:
a, b = [int(x) for x in input().split()]
ans = a - 2*b

if(ans < 0):
		ans=99

print(ans)		

Fixed code:
a, b = [int(x) for x in input().split()]
ans = a - 2*b

if(ans < 0):
		ans=0

print(ans)
Buggy code:
wsize,csize=[int(x) for x in input().split()]
widthconsumed=csize*2
result=wsize-widthconsumed
if result>csize:
    print(result)
else:
    print(0)


Fixed code:
wsize,csize=[int(x) for x in input().split()]
widthconsumed=csize*2
result=wsize-widthconsumed
if result>=0:
    print(result)
else:
    print(0)