import java.util.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int N = sc.nextInt(); int K = sc.nextInt(); int c=0; for(int i=2; i<=N; i++){ int t=i; int p=0; while(t%2==0){ t/=2; p=1; } int rt=(int)Math.sqrt(t); if(rt<3){rt=3;} for(int j=3; j<=rt; j+=2){ if(t%j==0){ p++; if(p>=K){break;} while(t%j==0){ t/=j; } } } if(t!=1){p++;} if(p>=K){c++;} } System.out.println(c); } }