import java.math.BigDecimal;
import java.math.BigInteger;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Collections;
import java.util.Scanner;

class Main {

    static final int MOD = 1000000007;

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        ArrayList<Integer> A = new ArrayList<Integer>();
        int N = sc.nextInt();
        int D = sc.nextInt();
        long ans = 1;
        for (int i = D; i < N; i += D * 2 + 1) {
            if (i + D + 1 < N)
                ans++;
        }
        System.out.println(ans);
    }
} import java.math.BigDecimal; BigDecimal java.math import java.math.BigInteger; BigInteger java.math import java.util.ArrayList; ArrayList java.util import java.util.Collection; Collection java.util import java.util.Collections; Collections java.util import java.util.Scanner; Scanner java.util class Main {

    static final int MOD = 1000000007;

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        ArrayList<Integer> A = new ArrayList<Integer>();
        int N = sc.nextInt();
        int D = sc.nextInt();
        long ans = 1;
        for (int i = D; i < N; i += D * 2 + 1) {
            if (i + D + 1 < N)
                ans++;
        }
        System.out.println(ans);
    }
} Main static final int MOD = 1000000007; MOD 1000000007 public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        ArrayList<Integer> A = new ArrayList<Integer>();
        int N = sc.nextInt();
        int D = sc.nextInt();
        long ans = 1;
        for (int i = D; i < N; i += D * 2 + 1) {
            if (i + D + 1 < N)
                ans++;
        }
        System.out.println(ans);
    } main {
        Scanner sc = new Scanner(System.in);
        ArrayList<Integer> A = new ArrayList<Integer>();
        int N = sc.nextInt();
        int D = sc.nextInt();
        long ans = 1;
        for (int i = D; i < N; i += D * 2 + 1) {
            if (i + D + 1 < N)
                ans++;
        }
        System.out.println(ans);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) ArrayList<Integer> A = new ArrayList<Integer>(); A new ArrayList<Integer>() int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc int D = sc.nextInt(); D sc.nextInt() sc.nextInt sc long ans = 1; ans 1 for (int i = D; i < N; i += D * 2 + 1) {
            if (i + D + 1 < N)
                ans++;
        } int i = D; int i = D; i D i < N i N i += D * 2 + 1 i += D * 2 + 1 i D * 2 + 1 D * 2 D 2 1 {
            if (i + D + 1 < N)
                ans++;
        } {
            if (i + D + 1 < N)
                ans++;
        } if (i + D + 1 < N)
                ans++; i + D + 1 < N i + D + 1 i + D + 1 i D 1 N ans++ ans System.out.println(ans) System.out.println System.out System System.out ans String[] args args
import java.math.BigDecimal;
import java.math.BigInteger;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Collections;
import java.util.Scanner;

class Main {

    static final int MOD = 1000000007;

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        ArrayList<Integer> A = new ArrayList<Integer>();
        int N = sc.nextInt();
        int D = sc.nextInt();
        long ans = 1;
        for (int i = D; i < N; i += D * 2 + 1) {
            if (i + D + 1 < N)
                ans++;
        }
        System.out.println(ans);
    }
}