import java.util.Scanner;
class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int K = sc.nextInt();
    int ans = ((N+(2*K+1)-1))/(2*K+1);
    System.out.print(ans);
  }
} import java.util.Scanner; Scanner java.util class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int K = sc.nextInt();
    int ans = ((N+(2*K+1)-1))/(2*K+1);
    System.out.print(ans);
  }
} Main public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int K = sc.nextInt();
    int ans = ((N+(2*K+1)-1))/(2*K+1);
    System.out.print(ans);
  } main {
    Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int K = sc.nextInt();
    int ans = ((N+(2*K+1)-1))/(2*K+1);
    System.out.print(ans);
  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc int K = sc.nextInt(); K sc.nextInt() sc.nextInt sc int ans = ((N+(2*K+1)-1))/(2*K+1); ans ((N+(2*K+1)-1))/(2*K+1) ((N+(2*K+1)-1)) N+(2*K+1) N (2*K+1) 2*K 2 K 1 1 (2*K+1) 2*K 2 K 1 System.out.print(ans) System.out.print System.out System System.out ans String[] args args
import java.util.Scanner;
class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int K = sc.nextInt();
    int ans = ((N+(2*K+1)-1))/(2*K+1);
    System.out.print(ans);
  }
}
