All pastes #403822 Raw Edit

Someone

public text v1 · immutable
·published 2007-03-20 17:36 UTC
rendered paste body
#include<iostream>
#include<math.h>
using namespace std;
int main()
{
    int n;
    double a,max=0;
    cin>>n;
    float x[50000],y[50000];
    for(int i=0;i<n;i++)
    {
            cin>>x[i]>>y[i];
            }
    for(int i=0;i<n;i++)
    {
            for(int j=i;j<n;j++)
            {
            a=pow(x[i]-x[j],2)+pow(y[j]-y[i],2);
            if(a>max)
            {
                     max=a;
            }
            }
    }
    printf("%.6f",pow(max,.5));
    cin>>a;
    return 0;
      
    
}