float X[300],Y[300],x,y,d;N,j,m,c;C(k){c=0;for(k=N;k--;c>m?m=c:0)c+=hypot(X[k]-x/2-X[j]-y*d,Y[k]-y/2-Y[j]+x*d)<1.0001;}main(i){for(;scanf("%d",&N)*N;printf("%d\n",m)){for(i=N;i--;)scanf("%f%f",X+i,Y+i);for(m=1;++i<N;)for(j=i;j--;d<4?C(d=sqrt(1/d-.25)),C(d=-d):0)x=X[i]-X[j],y=Y[i]-Y[j],d=x*x+y*y;}}