#include #include #include int main() { int *a,n,k,i,j,s=0; a=(int *)malloc(sizeof(int)*2000000); scanf("%d%d",&n,&k); memset(a,0,sizeof(int)*n); for (i=2;i<=n;i++) { if (!a[i]) for (j=i;j<=n;j+=i) a[j]++; s+=a[i]>=k; } printf("%d\n",s); return 0; }