#include<iostream>
#include<cstdio>
#include<cmath>
#include<algorithm>
using namespace std;
typedef struct
{
double x;
double y;
}pttype;
const long maxsize = 100000;
long arr[maxsize];
long arr1;
pttype pt[maxsize];
int sortcmp(const void *a, const void *b)
{
if (((pttype*)a)->x < ((pttype*)b)->x)
return -1;
else
return 1;
}
double dis(pttype a,pttype b)
{
return sqrt((a.x - b.x)*(a.x - b.x) + (a.y - b.y)*(a.y - b.y));
}
double getMin(double a, double b)
{
if(a<b)
return a;
else
return b;
}
int arrcmp(const void *a, const void *b)
{
if (pt[*(int*)a].y < pt[*(int*)b].y)
return -1;
else
return 1;
}
double shortest(long left,long right)
{
if(right-left == 1)
return dis(pt[left],pt[right]);
if(right-left == 2)
return getMin(getMin(dis(pt[left], pt[left+1]), dis(pt[left], pt[right])), dis(pt[left+1], pt[right]));
long i,j,mid = (left + right) >> 1;
double curmin = getMin(shortest(left,mid),shortest(mid +1 ,right));
arr1 = 0;
for (i = mid; i >= left && pt[mid+1].x - pt[i].x <= curmin; i --)
arr[arr1++] = i;
for (i = mid + 1; i <= right && pt[i].x - pt[mid].x <= curmin; i ++)
arr[arr1++] = i;
qsort(arr, arr1, sizeof(arr[0]), arrcmp);
for (i = 0; i < arr1; i ++)
for (j = i + 1; j < arr1 && pt[arr[j]].y - pt[arr[i]].y <= curmin; j ++)
curmin = getMin(curmin, dis(pt[arr[i]], pt[arr[j]]));
return curmin;
}
int main()
{
long n,i;
while(1)
{
scanf("%d",&n);
if(n == 0)
break;
for(i = 0;i < n;i++)
scanf("%lf%lf",&pt[i].x,&pt[i].y);
qsort(pt,n,sizeof(pt[0]),sortcmp);
printf("%.2lf\n",shortest(0,n-1)/2);
}
return 0;
}