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.



Sample input:
12 4


Sample output:
4

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
x,y = map(int,input().split())
out = x - y*2
if out > 0:    
    print(out)
else:
    print(0)

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A,B = input().split()

A = int(A)

B = int(B)

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input().split()
A = int(s[0])
B = int(s[1])
l = A-2*B
if l < 0:
  l=0
print(l)

Submission status: Accepted

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

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

print(result)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
import sys
readline = sys.stdin.buffer.readline

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

Submission status: Accepted

Solution code:
n,m=map(int,input().split())
print(max(0,n-2*m))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
# encoding:utf-8
import copy
import random
import bisect #bisect_left　これで二部探索の大小検索が行える
import fractions #最小公倍数などはこっち
import math
import sys
import bisect

mod = 10**9+7
sys.setrecursionlimit(mod) # 再帰回数上限はでdefault1000

def LI(): return list(map(int, sys.stdin.readline().split()))

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
length, curtain = map(int, input().split())

res = length - (curtain * 2)

print(res if res > 0 else 0)

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
l, c = map(int, input().split(' '))
if l <= 2*c:
    print(0)
else:
    print(l - (2*c))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# coding: utf-8

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
A, B = map(int,input().split())

s = int()

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

print(s)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
str = input().split() # sを取得し、strに値を入れる
a = int(str[0])
b = int(str[1])
ans = a - 2*b
if ans < 0:
    ans = 0
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
w, c = map(int, input().split())

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

Submission status: Accepted

Solution code:

if __name__ == '__main__':

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

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

Submission status: Accepted

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

s = A - (B*2)

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
import math

N,K=map(int,input().split())
print(max(N-K*2,0))

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A,B = (int(i) for i in input().split())

ans = A - (B*2)

if ans < 0:
  ans = 0

print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
[a,b] = input().split()

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

Submission status: Accepted

Solution code:
#!/usr/bin/env python3

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


if __name__ == "__main__":
    main()

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def print_ans(input_line):
    """Test Case
    >>> print_ans("12 4")
    4
    """
    A, B = list(map(int,input_line.split()))
    print(str(max(0,A - B * 2)))

if __name__ == '__main__':
    input_line = input()
    print_ans(input_line)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

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

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
aa, bb =input().split()
if int(aa)-2*int(bb)>0:
  print(int(aa)-2*int(bb))
else:
  print(0)

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a,b=[int(_) for _ in input().split()]
print([a-2*b,0][0>a-2*b])

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A,B = input().split()

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

if C < 0:
    print(0)
elif C > 100:
    print(100)
else:
    print(C)

Submission status: Accepted

Solution code:
A,B = input().split()

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

if C < 0:
    print(0)
elif C > 100:
    print(100)
else:
    print(int(C))

Submission status: Accepted

Solution code:
A,B = input().split()

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

if C < 1:
    print(0)
elif C > 100:
    print(100)
else:
    print(C)

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a, b = list(map(lambda x: int(x.strip()), input().split()))

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

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
a, b = map(int, input().split())

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution 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))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# -*- coding:utf-8 -*-

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

if __name__ == "__main__":
    solve()

Submission status: Accepted

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

Submission status: Accepted

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

c = a-2*b

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

Submission status: Accepted

Solution code:
import math

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

answer=0

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

print(answer)

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# -*- coding utf-8 -*-

MOD = 10 ** 9 + 7

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

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

print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = [int(a) for a in input().split(" ")]
a = s[0] - 2 * s[1]
print(0) if a < 0 else print(a)

Submission status: Accepted

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

if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import numpy as np
A, B = map(int, input().split())

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

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

Submission status: Accepted

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

if c < 0:
    print('0')
else:
    print(c)

Submission status: Accepted

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

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution 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)

Submission status: Accepted

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

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

print(x)

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:

def curtain():
    inStr = input().split()
    a = int(inStr[0])
    b = int(inStr[1])
    
    ans = a - b * 2
    if (ans <= 0):
        print(0)
    else:
        print(ans)
curtain()

Submission status: Accepted

Solution code:
#https://atcoder.jp/contests/abc143/tasks/abc143_a
A, B = list(map(int,input().split()))
print(max(A-2*B,0))

Submission status: Accepted

Solution code:
a, b = list(map(int, input().split()));
ans = 0;
if a > (b*2):
    ans = a - (b * 2);
print(ans);

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
from sys import stdin
a, b = [int(x) for x in stdin.readline().rstrip().split()]
if a <= 2*b:
    print(0)
else:
    print(a - 2*b)

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

print(ans)

Submission status: Accepted

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

ans = 0

if a - b*2 > 0:
    ans = a - b*2

print(ans)

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

ans=a-2*b

if ans<0:
    ans=0

print(ans)

Submission status: Accepted

Solution code:
"""
カーテンが2枚、縦は無視していいというのをすぐ把握すること。
カーテンの長さの合計が窓の長さを上回った時0になる。
制約
A,Bは整数
1≦A≦100
1≦B≦100
"""
#入力
A, B = map(int, input().split())

#計算
ans = A - 2 * B 

#判別&出力
if ans < 0:
  print(0)
else:
  print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
print(max(0, sum([i*j for i, j in zip(map(int, input().split()), [1, -2])])))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#
import sys
sys.setrecursionlimit(12345678)
import itertools
from collections import Counter
from collections import defaultdict
from collections import deque
import bisect
from heapq import heappush, heappop


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

if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

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

c = a - b * 2

if c < 0:
    c = 0

print(c)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import math
a,b = input().split()
a,b = int(a),int(b)
print(max(a-2*b,0))

Submission status: Accepted

Solution code:
a = input().split(" ")
a, b = int(a[0]), int(a[1]) * 2
r = a - b
print(r) if r > 0 else print(0)

Submission status: Accepted

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

Submission status: Accepted

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

ans = A - (2*B)

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = list(map(int, input().strip().split()))
a = n[0]
b = n[1]

c = a - 2 * b

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

ans = A - B * 2

print(0 if ans < 0 else ans)

Submission status: Accepted

Solution code:
A,B=map(int, input().split())  #複数数値入力　「A B」みたいなスペース空いた入力のとき

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
sys.setrecursionlimit(1000000000)
ii = lambda: int(input())
mis = lambda: map(int,input().split())
lmis = lambda: list(mis())
INF = float('inf')

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


if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:

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

c = a-(b*2)

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

Submission status: Accepted

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

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