'use strict';
const fs = require('fs');

let N = 0;
let X = [];
let Y = [];

function distance(i, j) {
    return Math.sqrt(Math.pow(X[i] - X[j], 2) + Math.pow(Y[i] - Y[j], 2));
}

function calcTotalRouteDistance() {
    let result = 0;
    for(let i = 0; i < N-1; ++i) {
        for(let j = i+1; j < N; ++j) {
            result += distance(i, j);
        }
    }
    return result;
}

function calcAverageDistance() {
    return 2 * calcTotalRouteDistance() / N;
}

function main(arg) {
    const lines = arg.split('\n');
    N = parseInt(lines[0], 10);
    for(let i = 0; i < N; ++i) {
        let line = lines[i + 1].split(/\s/);
        X[i] = parseInt(line[0], 10);
        Y[i] = parseInt(line[1], 10);
    }
    console.log(calcAverageDistance());
}

main(fs.readFileSync('/dev/stdin', 'utf8'));
