#include <iostream>
#include <algorithm>
#include <cmath>
#include<cstdio>
using namespace std;
struct node
{
double x,y;
}point[100000];
int n;
bool cmp(node p1,node p2)
{
if(p1.x != p2.x) return p1.x < p2.x;
else return p1.y < p2.y;
}
double dist(node a, node 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)
{
return a<b?a:b;
}
double solve(int l,int r)
{
//if(l == r)
// return 1000000000;
if(l == r - 1)
return dist(point[l],point[r]);
if(l == r - 2)
return getmin(getmin(dist(point[l],point[l+1]),dist(point[l+1],point[l+2])),dist(point[l],point[l+2]));
//int i,j,mid = (l+r) >> 1;
int i,j,mid=(l+r)/2;
double curmin = getmin(solve(l,mid),solve(mid+1,r));
for(i=l;i<=r;i++)
for(j=i+1;j<=i+5 && j<=r;j++)//避免超时
{
curmin = getmin(curmin,dist(point[i],point[j]));
}
return curmin;
}
int main()
{
int i;
while(scanf("%d",&n)!=EOF && n)
{
for(i=0;i<n;i++)
scanf("%lf %lf",&point[i].x,&point[i].y);
sort(point,point+n,cmp);
double ans = solve(0,n-1);
printf("%.2lf\n",ans/2);
}
return 0;
}
#include <algorithm>
#include <cmath>
#include<cstdio>
using namespace std;
struct node
{
double x,y;
}point[100000];
int n;
bool cmp(node p1,node p2)
{
if(p1.x != p2.x) return p1.x < p2.x;
else return p1.y < p2.y;
}
double dist(node a, node 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)
{
return a<b?a:b;
}
double solve(int l,int r)
{
//if(l == r)
// return 1000000000;
if(l == r - 1)
return dist(point[l],point[r]);
if(l == r - 2)
return getmin(getmin(dist(point[l],point[l+1]),dist(point[l+1],point[l+2])),dist(point[l],point[l+2]));
//int i,j,mid = (l+r) >> 1;
int i,j,mid=(l+r)/2;
double curmin = getmin(solve(l,mid),solve(mid+1,r));
for(i=l;i<=r;i++)
for(j=i+1;j<=i+5 && j<=r;j++)//避免超时
{
curmin = getmin(curmin,dist(point[i],point[j]));
}
return curmin;
}
int main()
{
int i;
while(scanf("%d",&n)!=EOF && n)
{
for(i=0;i<n;i++)
scanf("%lf %lf",&point[i].x,&point[i].y);
sort(point,point+n,cmp);
double ans = solve(0,n-1);
printf("%.2lf\n",ans/2);
}
return 0;
}