unittest
{
	assert( [ "3", "0 0", "1 0", "0 1" ].parse.expand.solve == "2.276142" );
	assert( [ "2", "-879 981", "-866 890" ].parse.expand.solve == "91.923882" );
	assert( [ "8", "-406 10", "512 859", "494 362", "-955 -475", "128 553", "-986 -885", "763 77", "449 310" ].parse.expand.solve == "7641.981782" );
}



import std.algorithm;
import std.conv;
import std.format;
import std.range;
import std.stdio;
import std.typecons;

void main()
{
	stdin.byLineCopy.parse.expand.solve.writeln;
}

auto parse( Range )( Range input )
if( isInputRange!Range && is( ElementType!Range == string ) )
{
	auto n = input.front.to!( long );
	auto xys = new long[ 2 ][ n ];
	foreach( ref xy; xys )
	{
		input.popFront;
		xy = input.front.split.to!( long[] );
	}
	return tuple( xys );
}

auto solve( long[ 2 ][] xys )
{
	auto f1 = reduce!( ( a, b ) => a * b )( iota( 1L, xys.length.signed ) );
	auto f2 = f1 * xys.length.signed;
	auto ans = 0.0L;
	foreach( i, a; xys )
	{
		foreach( b; xys[ i + 1 .. $ ] )
		{
			auto d = ( ( a[ 0 ] - b[ 0 ] ) ^^ 2 + ( a[ 1 ] - b[ 1 ] ) ^^ 2 ) ^^ 0.5L;
			ans += d * ( f1 * 2 );
		}
	}
	ans /= f2;
	return format( "%0.6f", ans );
}
