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:
from collections import deque
from heapq import heapify,heappop,heappush,heappushpop
from copy import copy,deepcopy
from itertools import product,permutations,combinations,combinations_with_replacement
from collections import defaultdict,Counter
from bisect import bisect_left,bisect_right
# from math import gcd,ceil,floor,factorial
# from fractions import gcd
from functools import reduce
from pprint import pprint

INF = float("inf")

def myinput():
    return map(int,input().split())

def mylistinput(n):
    return [ list(myinput()) for _ in range(n) ]

def mycol(data,col):
    return [ row[col] for row in data ]

def mysort(data,col,reverse_flag):
    data.sort(key=lambda x:x[col],reverse=reverse_flag)
    return data

def mymax(data):
    M = -1*float("inf")
    for i in range(len(data)):
        m = max(data[i])
        M = max(M,m)
    return M

def mymin(data):
    m = float("inf")
    for i in range(len(data)):
        M = min(data[i])
        m = min(m,M)
    return m

def mycount(ls,x):
    # lsはソート済みであること
    l = bisect_left(ls,x)
    r = bisect_right(ls,x)
    return (r-l)

def myoutput(ls,space=True):
    if space:
        if len(ls)==0:
            print(" ")
        elif type(ls[0])==str:
            print(" ".join(ls))
        elif type(ls[0])==int:
            print(" ".join(map(str,ls)))
        else:
            print("Output Error")
    else:
        if len(ls)==0:
            print("")
        elif type(ls[0])==str:
            print("".join(ls))
        elif type(ls[0])==int:
            print("".join(map(str,ls)))
        else:
            print("Output Error")

a,b = myinput()

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

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<=2*b:
    print(0)
else:
    print(a-2*b)

Submission status: Accepted

Solution code:
from statistics import median
#import collections
#aa = collections.Counter(a) # list to list || .most_common(2)で最大の2個とりだせるお a[0][0]
from fractions import gcd
from itertools import combinations # (string,3) 3回
from collections import deque
from collections import defaultdict
import bisect
#
#    d = m - k[i] - k[j]
#    if kk[bisect.bisect_right(kk,d) - 1] == d:
#
#
#
# pythonで無理なときは、pypyでやると正解するかも！！
#
#

import sys
sys.setrecursionlimit(10000000)
mod = 10**9 + 7

def readInts():
  return list(map(int,input().split()))
def main():
    a,b = readInts()
    print(a - b*2 if a - b*2 >= 0 else 0)
if __name__ == '__main__':
  main()

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())
print(max(a-2*b,0))

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
ans = max(0,a - 2*b )
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())
print(max(a-2*b, 0))

Submission status: Accepted

Solution code:
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 = map(int, input().split())

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

Submission status: Accepted

Solution code:
from sys import stdin
def main():
    #入力
    readline=stdin.readline
    A,B=map(int,readline().split())

    C=max(0,A-B*2)
    print(C)
if __name__=="__main__":
    main()

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
from collections import *

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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())
print(max(0, a - 2 * b))

Submission status: Accepted

Solution code:
def main():
    A, B = (int(i) for i in input().split())
    print(max(A - 2*B, 0))


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().strip().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())
print(A-2*B if A-2*B>=0 else 0)

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
print(max(0, a-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(max(0, 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<2*b:
    print(0)
else:
    print(a-2*b)

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
c=a-2*b
print(c if c>=0 else 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(0)
else:
    print(a-2*b)

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:
    print(0)
else:
    print(A-2*B)

Submission status: Accepted

Solution code:
A,B = map(int,input().split())
print(A-2*B) if A > 2*B else print(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())

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

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(max(0,a-2*b))

Submission status: Accepted

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

Submission status: Accepted

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

print( max(0, 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:
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())
ans = a - b * 2
if ans <= 0: print(0)
else : print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

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())
print(0 if a-2*b<0 else 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())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a,b=[int(_) for _ in input().split()]
print(max(0,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:
def main():
    a, b = map(int, input().split())
    print(max(0, a-2*b))


if __name__ == "__main__":
    main()

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 - (B*2))
else:
  print(0)

Submission status: Accepted

Solution code:
if __name__ == '__main__':
    a, b = map(int, input().split())
    print(max(0, 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())
ans = a - (b * 2)
if ans >= 0:
    print(ans)
else:
    print(0)

Submission status: Accepted

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

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


main()

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())
if a <=	2*b:
    print("0")
else:
    print(a-2*b)

Submission status: Accepted

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

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())
eq= 2*b
if eq < a:
	print(a-eq)
else:
	print("0")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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:
# -*- coding: utf-8 -*-

#############
# Libraries #
#############

import sys
input = sys.stdin.readline

import math
from collections import deque
from fractions import gcd
from functools import lru_cache


#############
# Constants #
#############

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

#############
# Functions #
#############

######INPUT######
def inputI(): return int(input().strip())
def inputS(): return input().strip()
def inputIL(): return list(map(int,input().split()))
def inputSL(): return list(map(str,input().split()))
def inputILs(n): return list(int(input()) for _ in range(n))
def inputSLs(n): return list(input().strip() for _ in range(n))
def inputILL(n): return [list(map(int, input().split())) for _ in range(n)]
def inputSLL(n): return [list(map(str, input().split())) for _ in range(n)]

#####Inverse#####
def inv(n): return pow(n, MOD-2, MOD)

######Combination######
kaijo_memo = []
def kaijo(n):
  if(len(kaijo_memo) > n):
    return kaijo_memo[n]
  if(len(kaijo_memo) == 0):
    kaijo_memo.append(1)
  while(len(kaijo_memo) <= n):
    kaijo_memo.append(kaijo_memo[-1] * len(kaijo_memo) % MOD)
  return kaijo_memo[n]

gyaku_kaijo_memo = []
def gyaku_kaijo(n):
  if(len(gyaku_kaijo_memo) > n):
    return gyaku_kaijo_memo[n]
  if(len(gyaku_kaijo_memo) == 0):
    gyaku_kaijo_memo.append(1)
  while(len(gyaku_kaijo_memo) <= n):
    gyaku_kaijo_memo.append(gyaku_kaijo_memo[-1] * pow(len(gyaku_kaijo_memo),MOD-2,MOD) % MOD)
  return gyaku_kaijo_memo[n]

def nCr(n,r):
  if(n == r):
    return 1
  if(n < r or r < 0):
    return 0
  ret = 1
  ret = ret * kaijo(n) % MOD
  ret = ret * gyaku_kaijo(r) % MOD
  ret = ret * gyaku_kaijo(n-r) % MOD
  return ret

######Factorization######
def factorization(n):
    arr = []
    temp = n
    for i in range(2, int(-(-n**0.5//1))+1):
        if temp%i==0:
            cnt=0
            while temp%i==0:
                cnt+=1
                temp //= i
            arr.append([i, cnt])
    if temp!=1:
        arr.append([temp, 1])

    if arr==[]:
        arr.append([n, 1])
    return arr

#####LCM#####
def lcm(a, b):
    return a * b // gcd (a, b)

#############
# Main Code #
#############

A,B = inputIL()

print(max(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()
(A,B)=(int(A),int(B))
Ans=A-(2*B)
if Ans<=0:
  Ans=0
print(Ans)

Submission status: Accepted

Solution code:
import os

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


if __name__ == "__main__":
	main()

Submission status: Accepted

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

if a > b * 2:
	print(a - b * 2)
elif a <= b * 2:
	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())
print(A - 2 * B if A - 2 * B >= 0 else 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());print(max(0,A-2*B))

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:
# -*- coding: utf-8 -*-

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

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

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())
print(max(0, A-B*2))

Submission status: Accepted

Solution code:

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

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

Submission status: Accepted

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

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:
def main():
    A, B = map(int, input().split())
    area = A - 2*B
    if area > 0:
        print(area)
    else:
        print(0)
if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

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

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(0)
else:
    print(a - 2*b)

Submission status: Accepted

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

ans = 0

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

Submission status: Accepted

Solution code:
import sys
import os
import math
import string

ii = lambda: int(sys.stdin.buffer.readline().rstrip())
il = lambda: list(map(int, sys.stdin.buffer.readline().split()))
fl = lambda: list(map(float, sys.stdin.buffer.readline().split()))
iln = lambda n: [int(sys.stdin.buffer.readline().rstrip()) for _ in range(n)]

iss = lambda: sys.stdin.buffer.readline().decode().rstrip()
sl = lambda: list(map(str, sys.stdin.buffer.readline().decode().split()))
isn = lambda n: [sys.stdin.buffer.readline().decode().rstrip() for _ in range(n)]

lcm = lambda x, y: x * y / math.gcd(x, y)

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


def main():
    if os.getenv("LOCAL"):
        sys.stdin = open("input.txt", "r")

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


if __name__ == '__main__':
    main()

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=[int(i)for i in 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(c)
else:
	print(0)

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
n=eval(input().replace(' ','-2*'));print(n if n>0 else 0)

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
#copy
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
else:
    ans = ans
    
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

if L>=0:
    print(L)
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())
j = A - 2 * B
if j > 0:
    print(j)
else:
    print(0)

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())
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())
if a < (b*2):
    print(0)
else:
    print(a-(b*2))

Submission status: Accepted

Solution code:
def main():
    import sys
    input = sys.stdin.readline
    sys.setrecursionlimit(10**7)
    from collections import Counter, deque
    #from collections import defaultdict
    from itertools import combinations, permutations, accumulate, groupby, product
    from bisect import bisect_left,bisect_right
    from heapq import heapify, heappop, heappush
    from math import floor, ceil
    #from operator import itemgetter

    #inf = 10**17
    #mod = 10**9 + 7

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

if __name__ == '__main__':
    main()

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 = (int(x) for x in 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())

m=a-2*b

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

Submission status: Accepted

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

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 = map(int,input().split())
if A<B*2:
    print(0)
else:
    print(A-2*B)

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
import sys
from bisect import bisect_right as bsr
from collections import Counter as cnt
from collections import defaultdict as dd
from collections import deque
from fractions import gcd
from itertools import permutations as perm
from math import ceil, factorial, floor
from operator import itemgetter as ig

sys.setrecursionlimit(1000000)

# お約束
args = None
INF = float("inf")
MOD = int(1e9 + 7)


def input(*ps):
    if type(ps[0]) is list:
        return [input(*ps[0][:-1]) for _ in range(ps[0][-1])]
    elif len(ps) == 1:
        return ps[0](next(args))
    else:
        return [p(next(args)) for p in ps]


def yesno(v, yes="Yes", no="No", upper=False):
    if upper:
        print([yes.upper(), no.upper()][not v])
    else:
        print([yes, no][not v])


def main():
    """エントリーポイント"""
    A, B = input(int, int)
    ans = A - B - B
    print(ans if 0 < ans else 0)


if __name__ == '__main__':
    args = iter(sys.stdin.read().split())
    main()

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 a < b * 2:
    print(0)
else:
    print(a-(b*2))

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
import math
import fractions
import sys
import itertools
import numpy as np
from collections import Counter
import datetime
#入力:N(int:整数)
def input1():
	return int(input())

#入力:N,M(int:整数)
def input2():
	return map(int,input().split())

#入力:[n1,n2,...nk](int:整数配列)
def input_array():
	return list(map(int,input().split()))

def keta(N):
	return len(str(N))


def input_daytime(input_time):
	time,distance=input_time.split()
	t=time.split(":")
	se=str(t[-1]).split(".")
	dt1 = datetime.timedelta(hours=int(t[0]),minutes=int(t[1]),seconds=int(se[0]),milliseconds=int(se[1]))
	return dt1

a,b=input2()

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:
    print(a - 2*b)
else:
    print(0)

Submission status: Accepted

Solution code:
#--curtain
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=map(int,input().split())
ans=a-b*2
if a<=b*2:
    ans=0
print(ans)

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

print(max(0, 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:
a, b = map(int, input().split())
print(max(0, a - 2 * b))

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

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:
  print(A - 2 * B)
else:
  print(0)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

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

Submission status: Accepted

Solution code:
x = input()
window = int(x.split()[0])
b = int(x.split()[1])
curtain = b * 2

if window > curtain:
    print(window - curtain)
else:
    print('0')

Submission status: Accepted

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

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

Submission status: Accepted

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

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:
N,M=map(int, input().split())
print(max(0,N-2*M))

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys
import numpy as np


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


# Generated by 1.1.6 https://github.com/kyuridenamida/atcoder-tools  (tips: You use the default template now. You can remove this line by using your custom template)
def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    A = int(next(tokens))  # type: int
    B = int(next(tokens))  # type: int
    solve(A, B)

if __name__ == '__main__':
    main()

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 = 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 - b * 2)
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 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:
    print(0)
else:
    print(a-b*2)

Submission status: Accepted

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

Submission status: Accepted

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

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())
if a <= b*2:
    print(0)
else:
    print(a- b*2)

Submission status: Accepted

Solution code:
# 初期入力
A,B = (int(x) for x in input().split())

#
sukima =A-B*2
if 0 < sukima:
    print(sukima)
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 = list(map(int, input().split()))
print(max(a - b - b, 0))

Submission status: Accepted

Solution code:
inp = list(map(int, input().split()))
a, b = inp[0], inp[1]
if a > b*2: print(a-b*2)
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:
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 2*b>=a:
	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:
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:
A,B = map(int,input().split())
if A <= 2*B:
    x = 0
else: x = A - 2*B
print(x)

Submission status: Accepted

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

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())
amari = a-b*2
if amari < 0:
    amari = 0
print(amari)

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=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<0:
    print('0')
else:
    print(a-2*b)

Submission status: Accepted

Solution code:
def q1():
    A,B = (int(i) for i in input().split())
    ans = max(0, A - B*2)
    print(ans)


if __name__ == '__main__':
    q1()

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:
import itertools
##print(ord("A"))
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:
    print(0)
else:
    print(a - b * 2)

Submission status: Accepted

Solution code:
a,b = list(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,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(0)
else:
  print(a-2*b)