#define _CRT_SECURE_NO_WARNINGS 1
#include <stdio.h>
#include<math.h>
double len(double A[], double B[], double C[])
{
double a = 0, b = 0, c = 0;
a = sqrt(pow((B[0] - C[0]), 2) + pow((B[1] - C[1]), 2));
b = sqrt(pow((A[0] - C[0]), 2) + pow((A[1] - C[1]), 2));
c = sqrt(pow((B[0] - A[0]), 2) + pow((B[1] - A[1]), 2));
double lent = a + b + c;
return lent;
}
int main()
{
double L = 0;
double a[1];
double b[1];
double c[1];
scanf("%lf %lf", &a[0],&a[1]);
scanf("%lf %lf", &b[0],&b[1]);
scanf("%lf %lf", &c[0],&c[1]);
L = len(a, b, c);
printf("%.2lf", L);
return 0;
}