Problem:
 Score : 100 points    Problem Statement The window of Takahashi's room has a width of A . There are two curtains hung over the window, each of which has a horizontal length of B . (Vertically, the curtains are long enough to cover the whole window.)  We will close the window so as to minimize the total horizontal length of the uncovered part of the window.
Find the total horizontal length of the uncovered parts of the window then.      Constraints  1 \leq A \leq 100  1 \leq B \leq 100  A and B are integers.         Input Input is given from Standard Input in the following format:  A  B       Output Print the total horizontal length of the uncovered parts of the window.        Sample Input 1 12 4      Sample Output 1 4  We have a window with a horizontal length of 12 , and two curtains, each of length 4 , that cover both ends of the window, for example. The uncovered part has a horizontal length of 4 .       Sample Input 2 20 15      Sample Output 2 0  If the window is completely covered, print 0 .       Sample Input 3 20 30      Sample Output 3 0  Each curtain may be longer than the window.

Solution (Python):
def solve(a, b):
    ans = a - 2 * b
    if ans < 0:
        return 0

    return ans


if __name__ == "__main__":
    raw = input()
    a, b = raw.split(' ')
    a, b = int(a), int(b)
    print(solve(a, b))

Solution (Python):
a,b=input().split()
a=int(a)
b=int(b)

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

Solution (Python):
A, B = map(int, input().split())

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

Solution (Python):
a,b = map(int,input().split())

an = a - b*2

if an < 0:
    an = 0
    
print (an)

Solution (Python):
A,B=map(int,input().split())
print(max(0,int(A-2*B)))

Solution (Python):
A, B = map(int,(input().split()))
result = A - (B * 2)
if result < 0:
  result = 0
print(result)

Solution (Python):
a, b = map(int, input().split())
out = a-b*2
if out < 0:
    out = 0
print(out)

Solution (Python):
A, B = map(int, input().split())

s = A - 2 * B 

if s <= 0:
    print(0)
else:
    print(s)

Solution (Python):
A,B=map(int,input().split())
print(max(A-B*2,0))

Solution (Python):
a,b = map(int,input().split())
if a <= b * 2:
    print(0)
elif a > b * 2:
    print(a - (b * 2))

Solution (Python):
A,B = map(int, open(0).read().split())

C = A-B*2

print("0" if C<=0 else C)

Solution (Python):
a,b=[int(i) for i in input().split()]
print(max([0,a-2*b]))

Solution (Python):
def solve():
    A, B = map(int, input().split())

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

if __name__ == '__main__':
    solve()

Solution (Python):
a,b = map(int,input().split())

c = a - b * 2
if c < 0:
    c = 0;

print(c)

Solution (Python):
def A():
    temp = [int(i) for i in input().split()]
    print(max(0, temp[0]-2*temp[1]))

A()

Solution (Python):
import sys


def main():
    a, b = [int(s) for s in sys.stdin.readline().strip().split()]

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



main()

Solution (Python):
a, b = map(int, input().split())

ans = a - 2 * b

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

Solution (Python):
import sys

def main():

	args = sys.argv
	A,B = (int(i) for i in input().split())
	
	if A > B*2 :
		print(A-B*2)
	else:
		print(0)
	

if __name__ == "__main__":
    main()

Solution (Python):
n,m = map(int, input().split())

x = m * 2
y = n - x

if (y < 0):
    y = 0

print(y)

Solution (Python):
A,B = map(int, input().split())

ans = A - (2*B)

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

Solution (Python):
XXX = input()

A = int(XXX.split(" ")[0])
B = int(XXX.split(" ")[1])

out = max(0, A - B * 2)

print(out)

Solution (Python):
a,b = map(int,input().split())

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

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

Solution (Python):
a,b = list(map(int,input().split()))
k = max(0,a-2*b)
print(k)

Solution (Python):
a,b=map(int,input().split())
print(max(0,a-2*b))

Solution (Python):
A, B = map(int,input().split())
Answer = max(A - 2*B, 0)
print(Answer)

Solution (Python):
a,b= [int(x) for x in input().split()]
if 2*b>=a:
  print(0)
else:
  print(a-2*b)

Solution (Python):
import sys
inputs = sys.stdin.readlines()
A, B = map(int, inputs[0].split())
print(max(0, A - 2*B))

Solution (Python):


A,B = map(int,input().split())

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

Solution (Python):
a,b = map(int, input().split())
print(max(0,a-2*b))

Solution (Python):
a,b = list(map(int,input().split()))
print(max(0,a-b*2))

Solution (Python):
A,B=map(int,input().split())
if A-2*B > 0:
  print(A-2*B)
else:
  print(0)

Solution (Python):


A, B = input().split(" ")

min_d = int(A) - 2 * int(B)

if(min_d <= 0):
    print(0)
else:
    print(min_d)

Solution (Python):
a,b = map(int,input().split())
print( a-2*b if a-2*b > -1 else 0)

Solution (Python):
import sys

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

    return max(0, A - 2 * B)

if __name__ == '__main__':
    print(main())

Solution (Python):
A,B=map(int,input().split())
print(max(0,A-2*B))

Solution (Python):
A, B = map(int, input().split())

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

Solution (Python):


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

Solution (Python):
a,b= map(int,input().split(" "))
c=a -2*b
if c>0:
  print(c)
else:
  print(0)

Solution (Python):
A,B=map(int,input().split())
if B*2>A:
    print(0)
else:
    print(A-B*2)

Solution (Python):
a,b=map(int,input().split())
print(max(a-(b*2),0))

Solution (Python):
A,B = map(int,input().split())
if B*2 >= A:
    print("0")
else :
    print(A-2*B)

Solution (Python):
a, b = map(int,input().split())
ans = max(a-2*b,0)
print(ans)

Solution (Python):
a,b = map(int, input().split())

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

Solution (Python):


import array
import math
import os
import sys


def main():
    A, B = read_ints()
    print(max(0, A - 2 * B))


DEBUG = 'DEBUG' in os.environ


def inp():
    return sys.stdin.readline().rstrip()


def read_int():
    return int(inp())


def read_ints():
    return [int(e) for e in inp().split()]


def dprint(*value, sep=' ', end='\n'):
    if DEBUG:
        print(*value, sep=sep, end=end)


if __name__ == '__main__':
    main()

Solution (Python):
A,B = map(int,input().split())
length = A-2*B
if length>=1:
    print(length)
else:
    print(0)

Solution (Python):
a,b = map ( int, input().split() )
c = a - 2*b
if c <= 0:
  print( 0 )
else:
  print( c )

Solution (Python):
A,B = map(int,input().split())
print(max([0,A-2*B]))

Solution (Python):
A, B = [int(x) for x in input().split()]
delta = A - (2 * B)

if delta > 0:
    print(delta)
else:
    print(0)

Solution (Python):
a, b = map(int, input().split())
print(max(a - b * 2, 0))

Solution (Python):
from enum import Enum
from queue import Queue
import collections

import sys
import math

BIG_NUM = 2000000000
MOD = 1000000007
EPS = 0.000000001

A,B = map(int,input().split())

print(max(A-B*2,0))

Solution (Python):
a,b = map(int,input().split(' '))
min = a -2*b
if min < 0:
  print(0)
else:
  print(min)

Solution (Python):
A, B = [int(v) for v in input().split()]

out = A - B * 2

if out < 0:
    out = 0

print(out)

Solution (Python):
a,b = [int(j) for j in input().split()]
print(max(a-2*b, 0))

Solution (Python):
a,b = map(int,input().split())

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

Solution (Python):
a,b = map(int, input().split())
x = a - 2 * b
print(x if x > 0 else 0)

Solution (Python):
A,B=map(int,input().split())
if B>A:
  print(0)
elif 2*B>A:
  print(0)
else:
  print(A-2*B)

Solution (Python):
A, B = map(int, input().split())

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

Solution (Python):
import sys
input = sys.stdin.readline

A,B = map(int,input().split())

C = B * 2

if A<C:
  print(0)
else:
  D = A - C
  print(D)

Solution (Python):
a = list(map(int,input().split()))
if a[1]*2<a[0]:
  print(a[0]-2*a[1])
else:
  print("0")

Solution (Python):

A, B = map(int, input().split())

c = A - 2*B

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

Solution (Python):
a,b = [int(i) for i in input().split()]
if 2*b>=a:
    print(0)
else:
    print(a-2*b)

Solution (Python):
a,b = map(int, input().split())
result = a - 2 * b
if result <= 0:
    print("0")
else:
    print(result)

Solution (Python):
a, b = map(int, input().split())
res = a - b * 2

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

Solution (Python):

import sys
read = sys.stdin.readline


def read_ints():
    return list(map(int, read().split()))


def read_a_int():
    return int(read())


def read_matrix(H):
    '''
    H is number of rows
    '''
    return [list(map(int, read().split())) for _ in range(H)]


def read_map(H):
    '''
    H is number of rows
    文字列で与えられた盤面を読み取る用
    '''
    return [read()[:-1] for _ in range(H)]


def read_col(H, n_cols):
    '''
    H is number of rows
    n_cols is number of cols

    A列、B列が与えられるようなとき
    '''
    ret = [[] for _ in range(n_cols)]
    for _ in range(H):
        tmp = list(map(int, read().split()))
        for col in range(n_cols):
            ret[col].append(tmp[col])

    return ret


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

Solution (Python):
a,b =map(int,input().split()) 

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

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

Solution (Python):
a, b = list(map(int, input().split()))
if a - b*2 > 0:
    print('{}'.format(a-b*2))
else:
    print(0)

Solution (Python):
A, B = map(int, input().split())
B = B*2

if B > A:
    print(0)
else:
    print(A-B)

Solution (Python):
a,b = map(int,input().split())
b*=2
if a <= b:
    print(0)
else:
    print(a-b)

Solution (Python):
a,b=map(int,input().split())
c=a-2*b
if c>0:
  print(c)
else:
  print(0)

Solution (Python):

import sys


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


def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word

    tokens = iterate_tokens()
    A = int(next(tokens))  
    B = int(next(tokens))  
    solve(A, B)


if __name__ == "__main__":
    main()

Solution (Python):


import sys
import math
import collections





tmp = input().split()
a,b = list(map(lambda a: int(a), tmp))



sum = a
sum -=b
sum -=b
if (sum<0):
	sum=0


print(sum)

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

Solution (Python):
A = list(map(int,input().split()))
sum =A[0] - 2*A[1]
if sum >=0:
    print(A[0] - 2*A[1])
else:
    print("0")

Solution (Python):
a,b= map(int,input().split())
c = max(0,a - 2 * b)
print(c)

Solution (Python):
import sys
def input():
    return sys.stdin.readline()[:-1]
A, B = map(int, input().split())
if A <= 2 * B:
  print(0)
else:
  print(A - 2*B)

Solution (Python):
m, n = map(int, input().split())
L = m-2*n
if L > 0:
    print(L)
else:
    print(0)

Solution (Python):
a,b=map(int,input().split())
answer=a-b*2
if answer<0:
  print(0)
else:
  print(answer)

Solution (Python):
A, B = map(int, input().split())

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

Solution (Python):
A, B = map(int,input().split())

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

Solution (Python):
from collections import Counter, defaultdict
import sys
sys.setrecursionlimit(10 ** 5 + 10)

from math import factorial
import heapq, bisect
import math
import itertools

import queue
from collections import deque



def main():
    a, b = map(int, input().split())
    print(max(a - b * 2, 0))






if __name__ == '__main__':
    main()

Solution (Python):
a=input().split()
b=int(a[0])
c=int(a[1])
if c*2>=b:
  print(0)
else: print(b-c*2)

Solution (Python):
a,b = map(int,input().split())
print(max(0,a-b*2))

Solution (Python):
a,b = (int(x) for x in input().split())
c=a-b*2
if c<0:
  print(0)
else:
  print(c)

Solution (Python):
A, B = map(int, input().split())
 
if A > 2*B:
  print(A - 2*B)
else:
  print(0)

Solution (Python):
a, b = map(int, input().split())
b_2 = b * 2

if b_2 >= a:
    print(0)
else:
    print(a - b_2)

Solution (Python):
A, B = list(map(int, input().split()))
C = max(A - 2 * B, 0)
print(C)

Solution (Python):
a, b = map(int, input().split())
if a <= b*2:
  print(0)
else:
  print(a-b*2)

Solution (Python):
A,B=map(int,input().split())

result=A-B*2

if result<=0:
  print(0)
else:print(result)

Solution (Python):
A, B = map(int, input().split())
ans = A - 2 * B
if ans < 0:
    ans = 0
print(ans)

Solution (Python):
A, B = map(int, input().split())
print(max(0, A-B*2))

Solution (Python):
N,M = map(int,input().split())
print(max(0,N-2*M))

Solution (Python):
a, b = map(int, input().split())
print(max(0, a - 2 * b))

Solution (Python):

A, B = map(int, input().split())

print(max(0, A - 2 * B))

Solution (Python):
from collections import defaultdict, deque
from heapq import heappush, heappop
from bisect import bisect_left, bisect_right
import sys
import random
import itertools
import math
sys.setrecursionlimit(10**5)
input = sys.stdin.readline
sqrt = math.sqrt


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


def LF(): return list(map(float, input().split()))


def LI_(): return list(map(lambda x: int(x)-1, input().split()))


def II(): return int(input())


def IF(): return float(input())


def LS(): return list(map(list, input().split()))


def S(): return list(input().rstrip())


def IR(n): return [II() for _ in range(n)]


def LIR(n): return [LI() for _ in range(n)]


def FR(n): return [IF() for _ in range(n)]


def LFR(n): return [LI() for _ in range(n)]


def LIR_(n): return [LI_() for _ in range(n)]


def SR(n): return [S() for _ in range(n)]


def LSR(n): return [LS() for _ in range(n)]


def gcd(x, y):
    if y == 0:
        return x
    return gcd(y, x % y)


def my_index_multi(l, x):
    return [i for i, _x in enumerate(l) if _x == x]


def sosu(x):
    for i in range(2, int(sqrt(x)+1)):
        if x % i == 0:
            return False
    return True


mod = 1000000007
inf = float('INF')


def A():
    A, B = LI()
    ans = A-2*B
    if ans > 0:
        print(ans)
    else:
        print(0)
    return




def B():
    n, m, W = LI()
    dp = [[0 for i in range(W+1)] for j in range(n+1)]
    wl = []
    vl = []
    c = [0 for i in range(n+1)]
    for i in range(n):

        w, v = LI()
        wl.append(w)
        vl.append(v)
    for i in range(m):
        a, b = LI()

        wl[a-1] += wl[b-1]
        vl[a-1] += vl[b-1]
        wl[b-1] = wl[a-1]
        vl[b-1] = vl[a-1]
        c[a] += 1
        c[b] += 2
    w = [x for i, x in enumerate(wl) if c[i+1] <= 1]
    v = [x for i, x in enumerate(vl) if c[i+1] <= 1]

    for i in range(len(w)):

        for t in range(W+1):

            if t >= w[i]:
                dp[i+1][t] = max(dp[i][t], dp[i][t-w[i]]+v[i])
            else:
                dp[i+1][t] = dp[i][t]

    print(max(dp[len(w)]))
    return




def C():
    N = II()
    A = LI()
    J = [0] * N
    for i, n in enumerate(A):
        J[n-1] = i+1
    for s in J:
        print(s, end=" ")

    return




def D():
    A, B = map(int, input().split())
    g = gcd(A, B)
    
    
    sq = int(sqrt(g)) + 2
    ans = 1

    for i in range(2, sq):
        if g % i == 0:
            ans += 1
        while g % i == 0:
            g /= i

            
        if g == 1:
            break
        if i == sq - 1:
            
            ans += 1

    print(ans)

    return




def E():
    N, M = LI()
    bit_max = 1 << N
    dp = [[inf for i in range(bit_max)] for j in range(M+1)]
    dp[0][0] = 0

    for i in range(M):
        a, b = LI()

        c = LI()
        bit = 0

        for d in c:
            bit |= 1 << (d-1)

        for w in range(bit_max):

            t = w | bit
            cost = dp[i][w] + a

            dp[i+1][t] = min(dp[i+1][t], cost)

            dp[i+1][w] = min(dp[i][w], dp[i+1][w])

    print(-1) if dp[-1][-1] == inf else print(dp[-1][-1])

    return




def F():
    N, M = LI()

    value = [0] * M
    power = [0] * M
    for i in range(M):
        a, b = LI()
        value[i] = a
        c = LI()
        L = ['0'] * N
        for k in c:
            L[k - 1] = '1'
        bint = ''.join(L)
        power[i] = int(bint, 2)
    bint = ''.join(list(['1'] * N))
    dp = [inf] * (int(bint, 2)+1)
    t = 0
    cost = 0

    dp[0] = 0
    for s in range(int(bint, 2) + 1):
        for i in range(M):
            t = s | power[i]
            cost = dp[s] + value[i]
            dp[t] = min(dp[t], cost)
    print(-1) if(dp[-1] == inf) else print(dp[-1])

    return

    



def solution(S):
    
    import math

    vowels = "AIUEO"
    count = 0
    consonants = 0
    newC = []
    newV = []

    for i in S[:-1]:
        if i in vowels:
            count += 1
            newV.append(i)
        else:
            consonants += 1
            newC.append(i)

    if consonants < count or consonants - 2 > count:
        return 0

    a = math.factorial(len(set(newC))) * math.factorial(len(set(newV)))
    return a

    pass



if __name__ == '__main__':
    A()

Solution (Python):
li=list(map(int, input().split()))
x = li[0] - li[1] * 2
if x < 0:
    print(0)
else:
    print(x)

Solution (Python):
a = input().split()
result = int(a[0]) - int(a[1]) * 2
if result <= 0:
    print(0)
else:
    print(result)

Solution (Python):
A,B=map(int,input().split())
if A-2*B>0:
  print(A-2*B)
else:
  print(0)

Solution (Python):
x, y = map(int, input().split())
output =  0 if x <= 2 * y else x - 2 * y
print(output)

Solution (Python):
a,b =map(int,input().split())

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

Solution (Python):
a,b = map(int,input().split())

s = a-b*2

if s > 0:
  print(s)
else:
  print(0)

Solution (Python):
a, b = map(int, input().split())

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

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

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


if __name__ == "__main__":
    main()

Solution (Python):
def main():
	import sys
	input = sys.stdin.readline
	
	a, b = map(int, input().split())
	print(max(0, a - 2 * b))
	
	return 0

main()

Solution (Python):
a,b=map(int,input().split())

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

Solution (Python):

window, curtain = map(int, input().split())
ans = window - (curtain * 2)
if ans <= 0:
  print(0)
else:
  print(ans)

Solution (Python):
A, B = map(int, input().split())
print(max(0, A - 2 * B))

Solution (Python):

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

Solution (Python):
def main():
  a, b = map(int, raw_input().split())
  length = a - 2*b
  print(length if length > 0 else 0)
  
main()

Solution (Python):
ab=input()
ab=ab.split()
a,b=ab[0],ab[1]
a=int(a)
b=int(b)
print(max(a-(2*b),0))

Solution (Python):
l = list(map(int, input().split()))
a = l[0]
b = l[1]
ans = a - b * 2
if (ans >= 0):
    print(ans)
else:
    print(0)

Solution (Python):
def main():
    a, b = map(int, input().split())
    temp = a - b*2
    if temp <= 0:
        temp = 0
    print(temp)


if __name__ == '__main__':
    main()

Solution (Python):
A,B = map(int,input().split())	

flag=A-2*B

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

Solution (Python):
A,B = list(map(int,input().split()))

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

Solution (Python):
a, b = map(int, input().split())
print(max(0, a-2*b))

Solution (Python):
if __name__ == '__main__':
    a, b = map(int, input().split())
    if a >=b:
        if a >= 2*b:
            print(a-2*b)
        else:
            print(0)
    else:
        print(0)

Solution (Python):
A,B=map(int,input().split())
ans=A-(2*B)
ans=max(ans,0)
print(ans)

Solution (Python):
a,b=map(int,input().split())
c=a-2*b
if c>0:
    print(c)
else:
    print(0)

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

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

Solution (Python):
AB = list(map(int,input().split()))
A = AB[0]
B = AB[1]

print(max(0, A-2*B))

Solution (Python):
i = list(map(int, input().split()))

if i[0] - (i[1] * 2) > -1:
    print(i[0] - (i[1] * 2))
else:
    print(0)

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

Solution (Python):
a, b = map(int, input().split())
print(max(0, a-b*2))

Solution (Python):
A, B = map(int, input().split())
if B*2 >= A:
  print(0)
else:
  print(int(A - B * 2))

Solution (Python):
a,b = map(int,input().split())

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

Solution (Python):
a, b = map(int, input().split())
ans = a - 2 * b
if ans < 0:
  ans = 0
print(ans)

Solution (Python):
a, b = map(int, input().split(' '))

ans = 0
w = a - (b*2)

if w > 0:
  ans = w 

print(ans)

Solution (Python):
A = list(map(int, input().split())) 
result = A[0] - 2 * A[1]

if result>0:
    print(result)
else:
        print(0)

Solution (Python):
def a():
    a_, b = map(int, input().split())
    res = a_ - b * 2
    print(res if res > 0 else 0)


if __name__ == '__main__':
    a()

Solution (Python):
A, B= [int(item) for item in input().split()]

temp_res = A - B * 2

if temp_res < 0:
    res = 0
else:
    res = temp_res

print(res)

Solution (Python):
A, B = map(int, input().split())

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

Solution (Python):

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



if a<2*b:
  ret = 0
else:
  ret = a-2*b


print(ret)

Solution (Python):
a, b = map(int, input().split())
c = a-2*b

if c > 0:
    print(c)
else:
    print(0)

Solution (Python):
a,b = map(int, input().split())
print(max(a-2*b,0))

Solution (Python):
A, B = map(int, input().split())
if A < B*2:
  print(0)
else:
  print(A-B*2)

Solution (Python):
import sys
input = sys.stdin.readline
sys.setrecursionlimit(1000000)
from collections import deque
def getN():
    return int(input())
def getList():
    return list(map(int, input().split()))
import math

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

Solution (Python):
a , b = map(int, input().split())
c = 0 if b * 2 >= a else a - b * 2
print(c)

Solution (Python):
import sys

A, B = [int(n) for n in sys.stdin.readline().strip().split()]
print(max(A-2*B, 0))

Solution (Python):
tmp = input()

tmp_s = [int(x.strip()) for x in tmp.split(' ')]
A = tmp_s[0] 
B = tmp_s[1] 

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

Solution (Python):
a,b = map(int,input().split())
if (a/2 - b) <= 0:
    print(0)
else:
    print(a - b*2)

Solution (Python):
A, B = map(int, input().split())
c_length = B * 2
remain = A - c_length
if remain < 0:
    print(0)
else:
    print(remain)

Solution (Python):
from sys import stdin
def main():
    a, b = list(map(int, input().split()))
    if a - 2 * b > 0:
        print(a - 2 * b)
    else:
        print(0)
    pass
if __name__ == '__main__':
    main()

Solution (Python):
A, B = map(int, input().split())
if A < 2 * B:
    print(0)
else:
    print(A - 2 * B)

Solution (Python):
A,B = map(int, input().split())
if A-2*B <= 0:
    print(0)
else:
    print(A-2*B)

Solution (Python):
a,b = map(int,input().split())
print(max(0,a-2*b))

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

if ans <= 0:
    ans = 0

print(ans)

Solution (Python):
A,B = map(int,input().split())

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

Solution (Python):
A, B = map(int, input().split())
if A <= B or A<= B*2:
  print(0)
else:
  print(A - B*2)

Solution (Python):
A, B = map(int, input().split())

num = A - (2 * B)

if num < 0:
    num = 0

print(num)

Solution (Python):
a, b = [int(v) for v in input().split(' ')]

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

Solution (Python):
A, B = map(int, input().split())

if A <= B * 2:
    ans = 0
else:
    ans = A - B * 2

print(ans)

Solution (Python):
A_B = input()
A_B_s = A_B.split(" ")
if (int(A_B_s[0])- 2 * int(A_B_s[1]) > 0):
  print(int(A_B_s[0])- 2 * int(A_B_s[1]))
else:
  print(0)

Solution (Python):
A,B = map(int,input().split())
l = A - 2* B
if l >= 0:
  print(l)
else:
  print(0)

Solution (Python):
a, b = map(int, input().split())
if a <= 2*b:
    print(0)
else:
    print(a - 2*b)

Solution (Python):

import sys


def main():
    A, B = list(map(int, input().split()))
    print(max(A-B*2, 0))


if __name__ == '__main__':
    main()

Solution (Python):
def main():
    a, b = [int(i) for i in input().split()]
    if b * 2 > a:
        print(0)
    else:
        print(a-b*2)


if __name__ == "__main__":
    main()

Solution (Python):



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

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

Solution (Python):
a,b = map(int,input().split())
print(max(0,a-2*b))

Solution (Python):
a, b = map(int,input().split())
c = a -2*b
if c <0 :
	c = 0
print(c)

Solution (Python):
a,b = map(int, input().split())
c=a-2*b
print(c if c>0 else 0)

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

Solution (Python):
a, b = map(int, input().split())
c = a -(b*2)
if c >=0:
  print(c)
else:
  print(0)

Solution (Python):
a, b = map(int, input().split())
print(max(a - 2 * b, 0))

Solution (Python):
a, b = map(int, input().split())

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

Solution (Python):
def main():
    a,b = map(int, input().split())

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

if __name__ == "__main__":
    main()

Solution (Python):
a, b = tuple(map(int, input().split()))
print(max(a - b * 2, 0))

Solution (Python):
A,B = map(int,input().split())
ans = max(0,(A-B*2))
print(ans)

Solution (Python):
a,b = [int(i) for i in input().split()]

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

Solution (Python):
a,b=map(int,input().split())
if a<2*b:
    print(0)
else:
    print(a-2*b)

Solution (Python):
A, B = (int(x) for x in input().split())


def solve():
    if A < B * 2:
        return 0

    return A - B * 2


print(solve())

Solution (Python):
A,B = map(int,input().split())
if 2*B>=A:
    print(0)
else:
    print(A-2*B)

Solution (Python):





a,b = map(int,input().split())
l = a-b*2

if l < 0:
    l = 0

print(l)

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

Solution (Python):
A, B = map(int,input().split())
if A - B*2 >= 0:
    print(A-B*2)
else:
    print(0)

Solution (Python):
A, B = map(int, input().split())

x = A - (B * 2)

if (x <= 0):
    print(0)
else:
    print(x)

Solution (Python):




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

res = a - b * 2
if res < 0:
    res = 0

print(res)

Solution (Python):
a,b=map(int,input().split(' '))
print(a-2*b if a-2*b>=0 else 0)

Solution (Python):
a,b = input().split(' ')
c = int(a)-2*int(b)
if c>=0:
    print(c)
else:
    print(0)

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

Solution (Python):
A,B = map(int,input().split())
print(max(0,A-B*2))

Solution (Python):
A, B =map(int, input().split())
ans = A - 2 * B
if ans >= 0:
    print(ans)
else:
    print(0)

Solution (Python):
A,B = [ int(x) for x in input().split()]

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

Solution (Python):

import sys
import math
import numpy as np
import itertools


a, b = (int(i) for i in input().split())  

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

Solution (Python):
A,B = map(int,input().split())

r = A - (2*B)

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

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

Solution (Python):
a, b = map(int, input().split())
print(max(0, a - 2 * b))

Solution (Python):
A, B = map(int, input().split())
d = A - 2 * B
print(d if d >= 0 else 0)

Solution (Python):
a,b=map(int,input().split())
print(max(0,a-b*2))

Solution (Python):
s = input().split()
a=int(s[0])
b=int(s[1])
if a>2*b:
    print(a-2*b)
else:
    print(0)

Solution (Python):
a, b = map(int, input().split())
print(max(a - b * 2, 0))

Solution (Python):
a,b = map(int,input().split())
a -= 2*b
if a < 0:
	print(0)
else :
	print(a)

Solution (Python):
import numpy as np

AB=np.array(input().split(),dtype=np.int32)

A=AB[0]
B=AB[1]

res=A-2*B

if(res<=0):
    print(0)
else:
    print(res)

Solution (Python):
A,B = map(int,input().split())

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

Solution (Python):
from copy import deepcopy
from sys import exit,setrecursionlimit
import math
from collections import defaultdict,Counter,deque
from fractions import Fraction as frac
import bisect
import heapq

import logging
logging.basicConfig(level=logging.DEBUG)

import sys
input = sys.stdin.readline().rstrip

setrecursionlimit(1000000)

MOD = 10**9+7
INF = float('inf')

def main():
    A,B=[int(x) for x in input().split()]
    ans = A - B*2
    print(ans if ans > 0 else 0)

main()

Solution (Python):
a, b = map(int, input().split())

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

Solution (Python):
a, b = map(int,input().split())
res = a - 2*b
if res <= 0:
    print(0)
else:
    print(res)

Solution (Python):
a,b=list(map(int,input().split()))
if a<=b*2:
  print(0)
else:
  print(a-b*2)

Solution (Python):
A, B = list(map(int, input().split()))
length = A - B*2
if length < 0:
    print(0)
else:
    print(length)

Solution (Python):
A, B = map(int, input().split())

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

Solution (Python):
A, B = map(int, input().split())



C = A - 2 * B
if C < 0:
    C = 0

print(C)

Solution (Python):
A,B=map(int,input().split())
if A<=2*B:
  print(0)
else:
  print(A-2*B)

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

Solution (Python):
a, b = map(int, input().split())

c = a - 2*b
ans = c if c>0 else 0

print(ans)

Solution (Python):
A,B = map(int,input().split())

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

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

Solution (Python):


A, B = map(int, input().split())

if A < B * 2:
	res = 0
else:
	res = A - B * 2

print(res)

Solution (Python):
A,B = map(int,input().split())
if A > (B*2):
    print(A-(B*2))
else:
    print(0)

Solution (Python):
A, B = (int(x) for x in input().split())
if A > 2 * B:
    print(A - 2 * B)
else:
    print(0)

Solution (Python):
a, b = (int(x) for x in input().split())
print(max(0,a-b*2))

Solution (Python):
A,B = [int(x) for x in input().split()]

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

Solution (Python):
A, B = map(int, input().split())

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

print(ans)

Solution (Python):
A,B=map(int,input().split())
if A>2*B:
    print(A-2*B)
else:
    print(0)

Solution (Python):
a, b = map(int, input().split())
print(max(0, a - b * 2))

Solution (Python):
import glob



REL_PATH = 'ABC\\143\\A'


TOP_PATH = 'C:\\AtCoder'

class Common:

    problem = []
    index = 0

    def __init__(self, rel_path):
        self.rel_path = rel_path

    def initialize(self, path):
        file = open(path)
        self.problem = file.readlines()
        self.index = 0
        return

    def input_data(self):
        try:
            IS_TEST
            self.index += 1
            return self.problem[self.index-1]

        except NameError:
            return input()

    def resolve(self):
        pass

    def exec_resolve(self):
        try:
            IS_TEST
            for path in glob.glob(TOP_PATH + '\\' + self.rel_path + '/*.txt'):
                print("Test: " + path)
                self.initialize(path)
                self.resolve()
                print("\n\n")
        except NameError:
            self.resolve()


class A(Common):

    def resolve(self):

        q = [int(i) for i in self.input_data().split()]
        a = q[0] - q[1]*2
        if a < 0:
            print("0")
        else:
            print(str(a))


solver = A(REL_PATH)
solver.exec_resolve()