#include<bits/stdc++.h>
using namespace std;
int dis(double x,double y,double x2,double y2){
return double(sqrt(pow(x-x2,2)+pow(y-y2,2)));
}
int main(){
double c=0,x1,y1,x2,y2,x3,y3;
scanf("%lf %lf\n%lf %lf\n%lf %lf",&x1,&y1,&x2,&y2,&x3,&y3);
c=dis(x1,y1,x2,y2)+dis(x1,y1,x3,y3)+dis(x2,y2,x3,y3);
printf("%.2lf",c);
return 0;
}