#include <stdio.h>
#include <math.h>
 
#define N_MAX 300
 
float point[N_MAX][2];
 
int main() {
  int n, big;
   
  while (scanf("%d\n", &n), n) {
    int i;
    float x, y;
     
    for (i = 0; i < n; i++) {
      scanf("%f %f\n", &point[i][0], &point[i][1]);
    }
     
    big = 0;
     
    for (x = 1; x < 10; x += 0.05) {
      for (y = 1; y < 10; y += 0.05) {
    int count = 0;
    for (i = 0; i < n; i++) {
      if (1.0 >=  (x - point[i][0]) * (x - point[i][0])
               + (y - point[i][1]) * (y - point[i][1])) {
        count++;
      }
    }
     
    if (count > big) {
      big = count;
    }
      }
    }
     
    printf("%d\n", big);
  }
   
  return 0;
}