var xx = IntArray(0)
var yy = IntArray(0)

fun main(args : Array<String>) {
    val n = readLine()!!.toInt()
    xx = IntArray(n){0}
    yy = IntArray(n){0}

    repeat(n) {
        val (x, y) = readLine()!!.split(" ").map { it.toInt() }
        xx[it] = x
        yy[it] = y
    }

    /*
    NOTE:

    A (0, 0)
    B (100 0)
    C (0, 100)

    AB -> 100
    AC -> 100
    BC -> 100√2

    ABC 100 + 100√2 => AB+BC
    ACB 100 + 100√2 => AC+BC
    BAC 100 + 100 => AB+AC
    BCA 100√2 + 100 => BC+AC
    CAB 100 + 100 => AB+AC
    CBA 100√2 + 100 => BC+AB
    —> AB*4 + BC*4 + AC*4
    => (AB+AC+BC)*4 / N! (== 3*2*1)
    => (AB+AC+BC)*2 / 3
    => (AB+AC+BC)*2 / N

    sum*2*(N-1)! / N!
    =>  sum*2 / N
    */
    var sum = 0.0
    for (i in 0 until n-1) {
        for (j in i+1 until n) {
            sum += Math.sqrt(Math.pow((xx[i]-xx[j]).toDouble(), 2.0) + Math.pow((yy[i]-yy[j]).toDouble(), 2.0))
        }
    }

    println(sum * 2 / n)
}