Problem:
 Score : 200 points    Problem Statement There are N apple trees in a row. People say that one of them will bear golden apples.  We want to deploy some number of inspectors so that each of these trees will be inspected.  Each inspector will be deployed under one of the trees. For convenience, we will assign numbers from 1 through N to the trees. An inspector deployed under the i -th tree (1 \leq i \leq N) will inspect the trees with numbers between i-D and i+D (inclusive).  Find the minimum number of inspectors that we need to deploy to achieve the objective.      Constraints  All values in input are integers.  1 \leq N \leq 20  1 \leq D \leq 20         Input Input is given from Standard Input in the following format:  N  D       Output Print the minimum number of inspectors that we need to deploy to achieve the objective.        Sample Input 1 6 2      Sample Output 1 2  We can achieve the objective by, for example, placing an inspector under Tree 3 and Tree 4 .       Sample Input 2 14 3      Sample Output 2 2       Sample Input 3 20 4      Sample Output 3 3

Solution (Python):
if __name__ == '__main__':
    n,d = map(int,raw_input().split())
    print -(- n // (d*2+1))

Solution (Python):
n,d=(int(x) for x in input().split())
d = d * 2 + 1
n = -(-n // d)
print(int(n))

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

def main():
	n, d = map(int, input().strip().split())
	p = n / (2*d+1)
	if p == int(p):
		print(int(p))
		return
	print(int(p+1))

if __name__ == '__main__':
	main()

Solution (Python):
import math

N,D = map(int, input().split())
print(math.ceil(N /(2 * D + 1)))

Solution (Python):
inputs = [int(x) for x in input().split()]

N = inputs[0]
D = inputs[1]
answer = 0
if N > (D*2) + 1:
  check = N % ((D*2) + 1)
  answer = N / ((D*2) + 1) 
  answer = int(answer)
  if check != 0:
    answer += 1
  
else:
  answer = 1
  
print(answer)

Solution (Python):
n,d = map(int,input().split())
ans = 0
for i in range(n):
    if ans * ( 2*d + 1) >= n:
        print(ans)
        exit()
    else:
        ans += 1
print(ans)

Solution (Python):
n, d = map(int, input().split())
obs = 1
while obs*(2*d+1) < n:
    obs += 1
print(obs)

Solution (Python):
N, D = [int(x) for x in input().split(" ")]

if N % (D*2 + 1) == 0:
    print(N // (D*2 + 1))
else:
    print(N // (D*2 + 1) + 1)

Solution (Python):
(N,D) = [int(x) for x in input().split()]
range = D * 2 + 1
ans = int(N / range) if N % range == 0 else int(N / range) + 1
print(ans)

Solution (Python):
n,d = map(int,input().split())
a = 2*d + 1
if n % a == 0:
    print(n//a)
else:
    print(n//a+1)

Solution (Python):


def main():
    N, D = map(int, input().split())
    syou = int(N / (D * 2 + 1))
    amari = N % (D * 2 + 1)
    if amari > 0:
        syou += 1
    print(syou)


if __name__ == '__main__':
    main()

Solution (Python):
n,d=map(int,input().split())
print((n-1)//(d*2+1)+1)

Solution (Python):
import math
N,D=map(int,input().split())
print(math.ceil(N/(2*D+1)))

Solution (Python):

import math
N,D = map(int,input().split())
print(math.ceil(N/(2*D+1)))

Solution (Python):
a,b = map(int,input().split())
ans = a // (b*2 + 1)
if a % (b*2 + 1) == 0:
  print(round(ans))
else:
  print(round(ans + 1))

Solution (Python):
n,d = map(int, input().split())
print(- (-n//(2*d+1)))

Solution (Python):
import math
n, d = map(int, input().split())
print(math.ceil(n/(2*d+1)))

Solution (Python):
n, d = map(int, input().split())
warukazu = 2*(d+1)-1
if n % warukazu == 0:
    print(n // warukazu)
else:
    print((n // warukazu) + 1)

Solution (Python):
from sys import stdin

def main():
    n, d = [int(x) for x in stdin.readline().rstrip().split()]
    print(-(-n//(d*2+1)))

if __name__ == '__main__':
    main()

Solution (Python):
from sys import stdin

def main():
    n, d = [int(x) for x in stdin.readline().rstrip().split()]
    cover = 2*d+1
    count = n // cover
    if n%cover != 0:
        count+=1

    print(count)

if __name__ == '__main__':
    main()

Solution (Python):
from sys import stdin

def main():
    n, d = [int(x) for x in stdin.readline().rstrip().split()]
    cover = 2*d+1
    count = n // cover
    if n%cover != 0:
        count+=1

    print(count)

if __name__ == '__main__':
    main()

Solution (Python):
N,D = map(int,input().split())
ans = -(-N//(2*D+1))
print(ans)

Solution (Python):
N,D = map(int,input().split())
man_num = N//(2*D+1)
if N%(2*D+1) != 0:
  man_num+=1
print(man_num)

Solution (Python):
n,d = map(int, input().split())
import numpy as np
m = 2*d+1
ans = np.ceil(n/m) 
print(int(ans))

Solution (Python):

import math

def solve():
    N, D = list(map(int, input().split()))
    print(math.ceil(N/(D*2+1)))

if __name__ == "__main__":
    solve()

Solution (Python):
import math
N,D = map(int, input().split())

print(math.ceil(N/(D*2+1)))

Solution (Python):
import math

N, D = map(int, input().split())
ret = N / (D * 2 + 1)
print(math.ceil(ret))

Solution (Python):
n, d = (int(x) for x in input().split())
tmpmin = n//(2*d+1)
if n%(2*d+1)!=0:
    tmpmin = tmpmin+1
print(tmpmin)

Solution (Python):
n, d = map(int, input().split())
 
if n%(2*d+1) == 0:
    print(n//(2*d+1))
else:
    print((n//(2*d+1))+1)

Solution (Python):
import math
N,D =map(int,input().split())

X = D * 2 + 1

pre_answer = N / X
print(math.ceil(pre_answer))

Solution (Python):
import math
inp = input().split()
n = int ( inp[0] )
d = int ( inp[1] )
x = math.ceil(n/(2*d+1))
print ( x )

Solution (Python):
N,D=map(int,input().split())
print((N-1)//(2*D+1)+1)

Solution (Python):
N, D = map(int, input().split())
print((N - 1) // (D * 2 + 1) + 1)

Solution (Python):
import math
N, D=map(int,input().split())
print(math.ceil(N/((D*2)+1)))

Solution (Python):
import math
n, d = [int(x) for x in raw_input().split()]
print(int(math.ceil(1.0*n/(2*d+1))))

Solution (Python):
from math import ceil
n,d=[int(i) for i in input().split()]
div = 2*d+1
print(ceil(n/div))

Solution (Python):
N,D=map(int,input().split())
print(N//(2*D+1)+int(N%(2*D+1)!=0))

Solution (Python):

def main():

    N,D = map(int,input().split())

    power = D*2+1

    if N <= power:
        print(1)
        exit()

    if N%power==0:
        print(int(N/power))
    else:
        print(int((N/power)+1))



if __name__== "__main__":
    main()

Solution (Python):
n,d=map(int,input().split())
if n%(2*d+1)==0:
  print(int(n/(2*d+1)))
else:
  print(int(n/(2*d+1))+1)

Solution (Python):
import math
n, d = map(int, input().split())
x = math.ceil(n / (d*2+1))
print(x)

Solution (Python):
N, D = map(int, input().split())
count = 0
check = 0
while(check < N):
    check += 2 * D + 1
    count += 1
print(count)

Solution (Python):
N, D = [int(_) for _ in input().split()]



import math
print(math.ceil(N / (2 * D + 1)))

Solution (Python):
import math

N, D = list(map(int, input().split()))

p=2*D+1
p = math.ceil(N/p)
print(p)

Solution (Python):
a, b = map(int, input().split())
print((a + (b * 2 + 1) - 1) // (b * 2 + 1))

Solution (Python):
import math
N, D = list(map(int, input().split()))
print(math.ceil(N/(D*2+1)))

Solution (Python):
N, D = map(int, input().split())

a = N // (2*D+1)
b = N %  (2*D+1)
if b != 0:
  b = 1
print(a+b)

Solution (Python):
N, D = map(int, input().split())
ans = 0
while N > 0:
  N -= ((D*2)+1)
  ans += 1
print(ans)

Solution (Python):
n, d = map(int, input().split())
import math
print(math.ceil(n/(2*d+1)))

Solution (Python):
N, D = map(int, input().split())

d = D*2+1

count = N // d
if N % d > 0:
    count += 1

print(count)

Solution (Python):
n,d=map(int,input().split())
c=1
i=d+1
while i<=n:
    if (i+d)>=n:
        break
    i+=(2*d+1)
    c+=1
print(c)

Solution (Python):
N,D=map(int,input().split())

z=1
while N>(2*D+1)*z:
  z=z+1
  
print(z)

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


if N[0]%(2*N[1]+1)==0:
 S=int(N[0]/(2*N[1]+1))
else:
 S=int(N[0]/(2*N[1]+1))+1
    
print(S)

Solution (Python):
N, D = map(int, input().split())

print(-(-N // (2*D+1) ))

Solution (Python):
N, D = map(int, input().split())

ans = - (N // -(2 * D + 1))
print(ans)

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

ans=N/(2*D+1)
int_ans=int(ans)

if ans-int_ans!=0:
    ans+=1

print(int(ans))

Solution (Python):
import math

N, D = map(int, input().split())

print(math.ceil(N / (2 * D + 1)))

Solution (Python):
import math
N, D = map(int, input().split())
i = N / (2*D + 1)
if 1 <= N <= 20 and 1 <= D <= 20:
    if i > 0:
        i = math.ceil(i)
        print(i)

Solution (Python):
import sys
import math
input = sys.stdin.readline
n, d = map(int, input().split())
print(math.ceil(n/(2*d+1)))

Solution (Python):
n, d = map(int, input().split())
print((n - 1) // (2 * d + 1) + 1)

Solution (Python):
N,D = map(int,input().split())
print(-(N//-(D*2+1)))

Solution (Python):


N, D = map(int, input().split())

monitorable_num = D * 2 + 1

guard_num = N // monitorable_num
additional = 0 if N % monitorable_num == 0 else 1
print(guard_num + additional)

Solution (Python):
import math

N,D = map(int, input().split())
ans = N / ( 2 * D + 1 )
print(math.ceil(ans))

Solution (Python):
N, D = [int(_) for _ in input().split()]

x = 1 + 2 * D
print((N - 1 + x) // x)

Solution (Python):
import sys
import math

if sys.platform =='ios':
  sys.stdin=open('input134b.txt')




n, d = map(int, input().split())

dsum = d * 2 + 1
print(math.ceil(n / dsum))

Solution (Python):
import math
n,d=map(int,input().split())

cap = 2 * d + 1
print(math.ceil(n/cap))

Solution (Python):
n,d = map(int,input().split())
view = d*2+1

if n%view==0:
    print(n//view)
else:
    print(n//view+1)

Solution (Python):
n,d=map(int,input().split())
o = int(n / (d*2+1))
if n % (d*2+1) == 0:
    print(o)
else:
    print(o+1)

Solution (Python):
n,d=map(int,input().split())
print(n//(2*d+1)+(1 if n%(2*d+1) else 0))

Solution (Python):
n,d=map(int,input().split())
quo = n//(2*d+1)
rem = n%(2*d+1)
if rem>0:
    quo+=1
print(quo)

Solution (Python):


n, d = map(int, input().split())
d = 2 * d  + 1

res = (n + d - 1) // d

print(res)

Solution (Python):

import sys
import math


def solve(N: int, D: int):
    print(math.ceil(N/(2*D+1)))
    return


def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    N = int(next(tokens))  
    D = int(next(tokens))  
    solve(N, D)

if __name__ == '__main__':
    main()

Solution (Python):
import math

N, D = map(int, input().split())
print(math.ceil(N/(2*D+1)))

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

if n%(d*2+1) == 0:
    print(n//(d*2+1))
else:
    print(n//(d*2+1)+1)

Solution (Python):
import math

N,D=input().split()
N=int(N)
D=int(D)
ans=math.ceil(N/(2*D+1))
print(ans)

Solution (Python):
N, D = map(int, input().split())
scope = 1 + D * 2
ans = int(N/scope) if N % scope == 0 else int(N/scope) + 1
print(ans)

Solution (Python):
N, D = map(int, input().split())
a =  N // (2 * D + 1)
b =  N % (2 * D + 1)
if b == 0:
  print(a)
else:
  print(a + 1)

Solution (Python):
n,d=map(int,input().split())
print((n-1)//(2*d+1)+1)

Solution (Python):
import math
N, D = map(int, input().split())

print(math.ceil(N/(D*2+1)))

Solution (Python):
n,d = map(int, input().split())
if n//(2*d+1) == n/(2*d+1):
  print(n//(2*d+1))
else:
  print(n//(2*d+1)+1)

Solution (Python):
lst = list(map(int,input().split()))
print((lst[0]+2*lst[1])//(2*lst[1]+1))

Solution (Python):
n, d = list(map(int,input().split(" ")))
ans = n//(1+2*d)
if n%(1+2*d) == 0:
  print(ans)
else:
  print(ans + 1)

Solution (Python):
n, d = map(int, input().split())
if n % ((2 * d)+1) != 0:
    ans = (n // ((2 * d) + 1)) + 1
else:
    ans = (n // ((2 * d) + 1))
print(ans)

Solution (Python):
import math
N, D = map(int, input().split())
all = 2 * D + 1
ans = math.ceil(N / all)
print(ans)

Solution (Python):
from math import ceil
N, D = map(int, input().split())
print(ceil(N/(2*D+1)))

Solution (Python):
import math
n,d = map(int, input().split())
print(math.ceil(n/(1+2*d)))

Solution (Python):
import math
n, d = map(int, input().split())
se = d * 2 + 1
print(math.ceil(n/se))

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

if n%(1+d+d) == 0:
  person = n//(1+d+d)
else:
  person = n // (1+d+d) + 1

print(person)

Solution (Python):
import math

N, D = [int(n) for n in input().split()]
print(math.ceil(N/(D*2+1)))

Solution (Python):
import math
N,D = map(int,input().split())
print(math.ceil(N/(D*2+1)))

Solution (Python):
import math
N,D = map(int,input().split())
range = 2*D +1
ans = math.ceil( N / range )
print(ans)

Solution (Python):
n,k = map(int,input().split())
if n % (k * 2 + 1) == 0:
  print(n//(k*2+1))
else:
  print(n//(k*2+1)+1)

Solution (Python):
n,d = map(int,input().split())
if n%(2*d+1) == 0:
    print(n//(2*d+1))
else:
    print(n//(2*d+1) + 1)

Solution (Python):
a, b = map(int, input().split())
c = b * 2 + 1
d = a // c
if a % c != 0:
    print(d + 1)
else:
    print(d)

Solution (Python):
N, D = map(int, input().split())
x = N // (D*2 + 1)
print(x + 1) if (D*2 + 1)*x < N else print(x)

Solution (Python):
N, D = map(int, input().split())
a = N // (2 * D + 1)
if N % (2 * D + 1) > 0:
    a += 1
print(a)

Solution (Python):

N,D = map(int, input().split())

look_len = D * 2 + 1

ans = N // look_len

am_zero = N % look_len
if am_zero != 0:
    ans += 1

print(ans)

Solution (Python):
N,D = map(int,input().split())
if N % (D*2+1) != 0:
  p = N // (D*2+1) + 1
else:
  p = N // (D*2+1)
  
print(p)

Solution (Python):
n, d = map(int, input().split())
c = int(n / (2*d+1))
if n > c * (2*d+1):
    c += 1
print(c)

Solution (Python):
N,D = map(int, input().split())
print(N//(D*2+1)+bool(N%(D*2+1)))

Solution (Python):
n,d = map(int,input().split())
 
if n % (d*2+1) != 0:
  print(int(n // (d*2+1) + 1)) 
else:
  print(int(n // (d*2+1)))

Solution (Python):
n,d = map(int,input().split())
 
if n % (d*2+1) != 0:
  print(int(n // (d*2+1) + 1)) 
else:
  print(int(n // (d*2+1)))

Solution (Python):
N,D=map(int,input().split())
span=D*2+1
count=0
for i in range(1,N+1):
    if i%span==0:
        count+=1

if N%span!=0:
    count+=1
print(count)

Solution (Python):
N,D=map(int,input().split())
span=D*2+1
count=0
for i in range(1,N+1):
    if i%span==0:
        count+=1

if N%span!=0:
    count+=1
print(count)

Solution (Python):
import math
N, D = list(map(int, input().split()))
print(str(math.ceil(N/(D*2+1))))

Solution (Python):
import math

N, D = map(int, input().split())

print(math.ceil(N/(2*D+1)))

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

for i in range(1, s[0] + 1):
    n = 2 * s[1] * i + i
    if s[0] <= n:
        ans = i
        break

print(ans)

Solution (Python):
N,D=map(int,input().split())

import math

print(math.ceil(N/(1+2*D)))

Solution (Python):
n, d = map(int, input().split())
import math
print(math.ceil(n/(1+2*d)))

Solution (Python):
n, d = map(int, input().split())
a = int((n+2*d)/(2*d+1))
print(a)

Solution (Python):
a=list(map(int,input().split()))
i=1
while i*(a[1]*2+1)<a[0]:
  i+=1


print(i)

Solution (Python):
ND = input()
N,D = [int(i) for i in ND.split(" ")]
D_2 = D*2 + 1

cnt = 1
while(1):
    if (D_2 * cnt) >= N:
        print(cnt)
        break
    cnt += 1

Solution (Python):
N,D=map(int, input().split())
c=0
while N>(2*D+1)*c:
    c=c+1
print(c)

Solution (Python):
N,D = map(int,input().split())
a = N//(2*D+1)
if N%(2*D+1) == 0:
	print(a)
else:
 	print(a+1)

Solution (Python):


n,d = map(int,input().split())
print((n+2*d)//(2*d+1))

Solution (Python):
n, d = map(int,input().split())
ans = n // (2*d + 1)
if n % (2*d + 1) == 0:
  print(ans)
else:
  print(ans+1)

Solution (Python):
N,D = map(int,input().split())

K = D * 2 + 1

if N < K:
  print(1)
elif N % K == 0:
  print(N // K)
else:
  print(N // K+1)

Solution (Python):
n, d = map(int, input().split())
print(n // (d * 2 + 1) + (n % (d * 2 + 1) != 0))

Solution (Python):
import math
n,d=map(int,input().split())
print(int((math.ceil(n/(2*d+1)))))

Solution (Python):
N, D = map(int,input().split())
hani = 2*D + 1
if N%hani == 0:
  ans = N//hani
else:
  ans = N//hani + 1
  
print(ans)

Solution (Python):
import sys

stdin = sys.stdin
read_int = lambda : list(map(int,stdin.readline().split()))
read_str = lambda : stdin.readline().rstrip()

N, D = read_int()

def solve():
    return -(-N // (2 * D + 1))

if __name__ == "__main__":
    print(solve())

Solution (Python):
import math
N, D = map(int,input().split())
ans = math.ceil(N/(2*D+1))
print(ans)

Solution (Python):
n,d = map(int, input().split())
res = 0
while n > 0:
  n -= d*2 + 1
  res += 1
print(res)

Solution (Python):
import math

N, D = map(int, input().split())
print( math.ceil(N/(2*D+1)) )

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

a = nd[0] // (nd[1]*2+1)

if (nd[0]%(nd[1]*2+1)) != 0:
    a += 1

print(a)

Solution (Python):
n, d = (int(x) for x in input().split())
ans = n / (d*2+1)
a = int(ans)
if ans > int(ans):
    ans=ans+1
print(int(ans))

Solution (Python):
n,d=map(int,input().split())
print((n+d+d)//(d+d+1))

Solution (Python):
n, d = [int(x) for x in input().split()]
print((n + 2*d) // (d*2 + 1))

Solution (Python):
n, d = map(int, input().split())
if n % (2*d + 1) == 0:
  print(n // (2*d + 1))
else:
  print(n // (2*d + 1) + 1)

Solution (Python):
n, d = map(int, input().split())
if n % (d * 2 + 1) == 0:
    print(n // (d * 2 + 1))
else:
    print(n//(d*2+1)+1)

Solution (Python):
n, d = map(int, input().split())
print(int((n + d + d) / (d + d + 1)))

Solution (Python):
import math

N, D = map(int, input().split())

print(int(math.ceil(N / (D * 2 + 1))))

Solution (Python):
n , d = map(int , input().split())
cnt = 0
while (n):
  cnt += 1
  n -= 2 * d + 1
  if (n <= 0) : break
print(cnt)

Solution (Python):
t,d = map(int,input().split())
p_a = t//(2*d+1)
p_b = t%(2*d+1)
if p_b == 0:
  print(p_a)
else:
  print(p_a + 1)

Solution (Python):
n,d=map(int,input().split())
import math
ans=math.ceil(n/(1+d*2))
print(ans)

Solution (Python):
N, D = map(int, input().split())
print(-(-N//(2*D+1)))

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

c = a//(2*b+1)


if a % (2*b+1) ==0:
  print(c)
  
else:
  print(c+1)

Solution (Python):
N,D=map(int,input().split())
print(int((N+D*2)/(D*2+1)))

Solution (Python):
import sys

def main():
    input = sys.stdin.readline
    N, D = map(int, input().split())
    
    r = D * 2 + 1
    q , mod = divmod(N, r)
    
    print(q if mod == 0 else q + 1)
    
if __name__ == '__main__':
    main()

Solution (Python):
N, D = map(int,input().split())
import math
print(math.ceil(N/(D*2 + 1)))

Solution (Python):
n, d = map(int, input().split())
q, mod = divmod(n, d * 2 + 1)

if mod == 0:
    print(q)
else:
    print(q+1)

Solution (Python):
n,d = (int(i) for i in input().split())

d = d*2 +1
if d >= n:
    ans = 1
else:
    q = n//d
    mod = n % d
    ans = q
    if mod != 0:
        ans += 1

print(ans)

Solution (Python):
N, D = map(int,input().split())
if (N%(2*D+1) == 0):
  print(N//(2*D+1))
else:
  print(N//(2*D+1)+1)

Solution (Python):
n, d = map(int, input().split())
print(n//(2*d+1) + bool(n%(2*d+1)))

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

ans = n // (2*d+1)
if n%(2*d+1) > 0:
    ans += 1

print(ans)

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

temp = d + 1
res = 1
while temp < n - d:
    temp += 2 * d + 1
    res += 1

print(res)

Solution (Python):
N,D = map(int, input().split())
print((N-1)//(2*D+1)+1)

Solution (Python):
N, D = map(int, input().split())

print((N+2*D)//(2*D+1))

Solution (Python):
import math 

n,d = map(int,input().split())

result = math.ceil(n /(2 * d + 1))

print(result)

Solution (Python):
N, D = map(int, input().split())
A = N // (2*D+1)

if N%(2*D+1) == 0:
  print(A)
else:
  print(A+1)

Solution (Python):
import math
n, d = map(int,input().split())
print(math.ceil(n/(d*2+1)))

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

calc = (n + 1) // (d * 2 + 1)
mod = (n + 1) % (d * 2 + 1)

if mod <= 1:
    ans = calc
else:
    ans = calc + 1

print(ans)

Solution (Python):
n, d = list(map(int, input().split()))
if n % (d * 2 + 1) == 0: 
    print(n // (d * 2 + 1))
else:
    print(n // (d * 2 + 1) + 1)

Solution (Python):
import math
n, d = map(int, input().split())
d = 2 * d + 1
print(math.ceil(n / d))

Solution (Python):
n , d = map(int, input().split())
ans = -(-n // (2*d+1))
print(ans)

Solution (Python):
shuru=input()
shuru=shuru.split()
n=int(shuru[0])
d=int(shuru[1])
d=2*d+1
ans=n//d
if n%d!=0 :
  ans+=1
print(ans)

Solution (Python):
N,D=map(int,input().split())
a=2*D+1
b=N//a
c=N%a
if c==0:
    b=b
else:
    b=b+1
print(b)

Solution (Python):
n,d=map(int,input().split())
print(-(-1*n//(2*d+1)))

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

s = N % (2 * D + 1)
n = int(N / (2 * D + 1))

if s == 0:
    print(n)
else:
    print(n+1)

Solution (Python):
N,D=map(int, input().split())
b2=D*2+1
print(-(-N//b2))

Solution (Python):
nd = [int(i) for i in input().split()]
n = nd[0]
d = nd[1]
i = 0
while True:
    if n <= (2*d+1)*i:
        flag = i
        break
    else:
        i = i + 1
        
print(flag)

Solution (Python):
N, D = map(int, input().split())

if N % (2*D + 1) == 0:
  print(N // (2*D + 1))
else:
  print(N // (2*D + 1) + 1)

Solution (Python):
N, D = map(int, input().split())
ans = N // (2 * D + 1) + int(N - N // (2 * D + 1) * (2 * D + 1) > 0)
print(ans)

Solution (Python):
i = input().split(" ")
n = int(i[0])
d = int(i[1])

if n%(2*d+1) == 0:
    print(int(n/(2*d+1)))
else:
    print(int(n/(2*d+1)+1))

Solution (Python):
import math

S = input()

S = S.split()

N = int(S[0])
D = int(S[1])

print(math.ceil(N/(2*D+1)))

Solution (Python):


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


if a % (b*2+1) == 0:
    print(a//(b*2+1))
else:
    print(a//(b*2+1)+1)

Solution (Python):
a,b=map(int, input().split())
b2=b*2+1
print(-(-a//b2))

Solution (Python):
if __name__ == '__main__':
    N, D = map(int, input().split())

    print((N + 2*D+1-1)//(2*D+1))

Solution (Python):
import math
N, D = list(map(int, input().split()))

print(math.ceil(N / (2 * D + 1)))

Solution (Python):
n, d = map(int, input().split())
if n % (d*2+1) == 0:
    print(n//(d*2+1))
else:
    print(n//(d*2+1) + 1)

Solution (Python):
import math
n,d = map(int,input().split())
print(math.ceil(n/(d*2+1)))

Solution (Python):
n,d = map(int, input().split(" "))
width = 2*d + 1
ans = n//width
if n%width == 0:
    print(ans)
else:
    print(ans+1)

Solution (Python):



def main():
    from math import ceil

    n, d = map(int, input().split())
    print(ceil(n / (2 * d + 1)))


if __name__ == '__main__':
    main()

Solution (Python):
INPUT_SENTENCES = 1                                                                                                                                                                                                 
ss = [input() for i in range(INPUT_SENTENCES)][0].split(" ")                                                                                                                                                        
N = int(ss[0])                                                                                                                                                                                                      
D = int(ss[1])                                                                                                                                                                                                      
result = []                                                                                                                                                                                                         
s = 0                                                                                                                                                                                                               
cnt = 0                                                                                                                                                                                                             
for i in range(N):                                                                                                                                                                                                  
    s += 2*D+1                                                                                                                                                                                                      
    cnt += 1                                                                                                                                                                                                        
    if s >= N:                                                                                                                                                                                                      
        break                                                                                                                                                                                                       
print(cnt)

Solution (Python):
import math

n,d=map(int,input().split())
x=2*d+1
print(math.ceil(n/x))

Solution (Python):
N, D = map(int, input().split())

k = 2*D + 1
ans = N // k
mod = N % k
if mod != 0:
    ans += 1
    
print(ans)

Solution (Python):
N, d = map(int, input().split())

D=2*d+1
syou=N//D
amari=N%D

if amari != 0:
  syou=syou+1

print(syou)

Solution (Python):
n,d = map(int,input().split())
kotae = n // (d*2 + 1) + 1
if n % (d*2 + 1) == 0:
  kotae = n // (d*2 + 1)
print(kotae)

Solution (Python):
N,D=map(int,input().split(" "))
mem=0
while N>(D*2+1)*mem:
    mem+=1
print(mem)

Solution (Python):
n,d=map(int,input().split())
a=2*d+1
b=1
if n%a==0:
    b=0
print(n//a+b)

Solution (Python):
n,d = map(int,(input().split()))
q,r = divmod(n,(2*d+1))
if r==0:
    answer = q
else:
    answer = q+1
print(answer)

Solution (Python):



import itertools as ite
import math
import random
import sys
import codecs
from collections import defaultdict

INF = 10 ** 18
MOD = 10 ** 9 + 7

sys.setrecursionlimit(1000000)

N, D = map(int, raw_input().split())
print N / (2 * D + 1) + (N % (2 * D + 1) != 0)

Solution (Python):
import math
N,D=map(int,input().split())
print(math.ceil(N/(D*2+1)))

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

d = d*2+1

for i in range(1,n+1):
    n -= d
    if n < 1:
        break

print(i)

Solution (Python):
import math


N, D = map(int, input().split())

print("{}".format(math.ceil(N / (2 * D + 1))))

Solution (Python):
n,d = map(int,input().split())
if n%(2*d+1) == 0:
    print(n//(2*d+1))
else:
    print(n//(2*d+1)+1)

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

ans =  n // (2*d +1)

print(ans+1 if n % (2*d+1) != 0 else ans)

Solution (Python):
from math import ceil
N, D = map(int, input().split())
print(ceil(N / (2*D+1)))

Solution (Python):
import math
N, D = map(int, input().split())
k = 2 * D + 1
print(math.ceil(N / k))

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

Solution (Python):
n, d = map(int,input().split())
h = d * 2 + 1
c = int(n / h)
if(n % h == 0):
    print(c)
else:
    print(c+1)

Solution (Python):
from math import ceil
n, d = map(int, input().split())
print(ceil(n/(2*d+1)))

Solution (Python):

import math

n,d=map(int,raw_input().split())
print int(math.ceil(1.0*n/(2*d+1)))

Solution (Python):
N, D = map(int, input().split())
ans = N // (2 * D + 1)
print(ans + 1 if N % (2 * D + 1) !=0 else ans)

Solution (Python):
N,D = map(int,input().split())
S = 0
cnt = 0
while S < N:
  S += 1+2*D
  cnt +=1
print(cnt)

Solution (Python):
N,D = map(int,input().split())
print(-(-N//(2*D+1)))

Solution (Python):
n,m=map(int,input().split());
l=int(n/(2*m+1));
if(n%(2*m+1)!=0):
    l+=1;
print(l);

Solution (Python):




import math
import statistics

n,d = map(int, input().split())
print((n + d * 2) // (d * 2 + 1))

Solution (Python):
import math
n ,d = map(int, input().split())
print(math.ceil(n/(d*2+1)))

Solution (Python):
n,d = map(int,input().split())
print(-(-n//(2*d+1)))

Solution (Python):
from heapq import heappush, heappop
import re
from collections import deque
import sys
import math
input = sys.stdin.readline


def int_raw():
    return int(input())


def ss_raw():
    return input().split()


def ints_raw():
    return tuple(map(int, ss_raw()))


DIV = 10**9+7


def mod_inv_prime(a, mod=DIV):
    return pow(a, mod-2, mod)


def mod_inv(a, b):
    r = a
    w = b
    u = 1
    v = 0
    while w != 0:
        t = r//w
        r -= t*w
        r, w = w, r
        u -= t*v
        u, v = v, u
    return (u % b+b) % b


def ncr(n, r, mod=DIV):
	r = min(r, n-r)
	ret = 1
	for i in range(1, r+1):
		ret = ret * (n-i+1) % mod
		ret = ret * mod_inv(i, mod) % mod
	return ret


def main():
    N,D = ints_raw()
    D2 = D*2+1
    return (N+D2-1)//D2
print(main())

Solution (Python):
N,D = map(int, input().split())

print(-(-N//(1+D*2)))

Solution (Python):
n,d = map(int,input().split())
human = n // (2*d + 1)
if n % (2*d + 1) != 0:
    human += 1
print(human)

Solution (Python):
n,d=map(int,input().split())
if n%(2*d+1)==0:
  print(n//(2*d+1))
else:
  print(n//(2*d+1)+1)

Solution (Python):
N,D = map(int,input().split())
A = D*2 + 1
print(N//A + (N%A != 0))

Solution (Python):
import math
N, D = map(int, input().split())
print(math.ceil(N / (2 * D + 1)))

Solution (Python):
n,d = map(int,input().split())
from math import ceil
print(ceil(n/(2 * d + 1)))

Solution (Python):
N, D = map(int, input().split())

D = 2 * D + 1

print((N // D) if N % D == 0 else (N // D + 1))

Solution (Python):
N, D = map(int, input().split(" "))

print(-(-N//(2*D+1)))

Solution (Python):
n,d = map(int,input().split())
print((n+d*2)//(d*2+1))

Solution (Python):
N,D=map(int,input().split())

n=1
while N>(2*D+1)*n:
  n=n+1

print(n)

Solution (Python):
N,D=map(int,input().split())
a=N//(D*2+1)
a+=1 if N%(D*2+1)!=0 else 0
print(a)

Solution (Python):
n,d=map(int,input().split())
res=0
ans=0
for i in range(1,n+1):
    res=res+(2*d)+1
    if res>=n:
        ans=i
        break
print(ans)

Solution (Python):
n,d=map(int,input().split());print(n//(d*2+1)if n%(d*2+1)==0 else n//(d*2+1)+1)

Solution (Python):
def main11():
    data = input().split()
    num = []
    for i in range(2):
        num.append(int(data[i]))
    result = int(num[0] / (num[1] * 2 + 1))
    if int(num[0] % (num[1] * 2 + 1)) != 0:
        result = result + 1
    print(result)

if __name__ == "__main__":
    main11()

Solution (Python):
N, D = map(int, input().split())
if N % (2 * D + 1) == 0:
    print(N // (2 * D + 1))
else:
    print(N // (2 * D + 1) + 1)

Solution (Python):
n, d = map(int, input().split())
print(n//(2*d+1)+(1 if n%(2*d+1)!=0 else 0))

Solution (Python):
n, d = list(map(int, input().split()))
s = d * 2 + 1

if n % s == 0:
    print(n // s)
else:
    print(n // s + 1)

Solution (Python):
N, D = map(int, input().split())

d, m = divmod(N, 2 * D + 1)
if m != 0:
    d += 1
print(d)

Solution (Python):
N, D = map(int, input().split())
d = 2 * D + 1
print((N + d - 1) // d)

Solution (Python):
N, D = map(int, input().split())
print(- (-N // (2 * D + 1)))

Solution (Python):
N,D = map(int,input().split())



x = 2*D+1
y = N//x
z = N%x
if z==0:
    print(y)
else:
    print(y+1)

Solution (Python):
n,d=map(int,input().split())
x=d*2+1
print(n//x+(0 if n%x==0 else 1))

Solution (Python):
n,d=input().split()
i=1+int(d)*2
count=1
while i<int(n):
    count+=1
    i=i+int(d)*2+1
print(str(count))

Solution (Python):
n,d=input().split()
n=int(n)
d=int(d)
a=d*2+1
if n%a==0:
    print(n//a)
else:
    print(n//a+1)

Solution (Python):
inputLine = input().split()
N = int(inputLine[0])
D = int(inputLine[1])

eyeSight = 1 + D * 2
answer = int(N / eyeSight)
if(N % eyeSight != 0):
  answer += 1
  
print(answer)