data class Xy(val x: Double, val y: Double) {
    constructor(xy: List<Double>): this(xy[0], xy[1])
}
fun main(args: Array<String>) {
    val N = nextInt()
    val XY = Array(N) { Xy(listOfDouble()) }
    val A = IntArray(N)
    var count = 0
    var sum: Double = 0.0
    fun Distance(n: Int, m: Int): Double {
        val dx = Math.abs(XY[n].x - XY[m].x)
        val dy = Math.abs(XY[n].y - XY[m].y)
        return Math.sqrt(dx * dx + dy * dy)
    }
    fun Permutation(n: Int) {
        if (n == N) {
            count += 1
            for (m in 0 until N - 1) {
                sum += Distance(A[m], A[m + 1])
            }
        } else {
            for (m in 0 until N) {
                if (A.slice(0 until n).all { it != m }) {
                    A[n] = m
                    Permutation(n + 1)
                }
            }
        }
    }
    Permutation(0)
    val ans = sum / count
    println(ans)
}
fun next() = readLine()!!
fun listOfString() = next().split(" ")
fun nextInt(delta: Int = 0) = Integer.parseInt(next()) + delta
fun listOfDouble() = listOfString().map(String::toDouble)
