/**
*1的个数 AC
*/
import java.util.Scanner;
public class Main{ public static void main(String[] args){ Scanner sc = new Scanner(System.in); while(sc.hasNext()){ sc.nextLong(); System.out.println(1+sc.nextLong()-sc.nextLong()); } }
}
/***
第二题 AC 进制 最大数
**/
import java.util.Scanner;
public class Main { public static void main(String[] args) { Scanner sc=new Scanner(System.in);
while(sc.hasNext()){
long n=sc.nextLong();
long max=1;
long num=0;
num=jingzhi(n,n/2-1);
if(max<num)max=num;
num=jingzhi(n,n/2);
if(max<num)max=num;
num=jingzhi(n,(n/2+1));
if(max<num)max=num;
System.out.println(max);
} } private static long jingzhi(long n, long i) { long sum=0; while(n>0){ sum+=n%i; n/=i; } return sum; }
}
/***
第三题通过70% 回文串数
**/
import java.math.BigDecimal;
import java.util.*;
public class Main {
public static void main(String[] args) { Scanner sc=new Scanner(System.in); while(sc.hasNext()){ BigDecimal ns=new BigDecimal(sc.nextLine()); int count=0; long n=ns.longValue(); for(long i=0;i<=n;i++){ String str=Long.toBinaryString(i); if(huiwen(str)==1) count++; } System.out.println(count); } }
public static int huiwen(String str){ StringBuffer strb=new StringBuffer(str); String str2=strb.reverse().toString(); if(str2.equals(str))return 1; else return 0;
}
}