{ll@n,@k,c;VI@p(n);rep(i,401){c=0;for(int a:p)if(a>=i)c++;if(c<=k){wt(c);return 0;}}}