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

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

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