import numpy as np

import itertools

N = int(eval(input()))

p = [list(map(int,input().split())) for _ in range(N)]

print((sum(np.sqrt((p[i][0] - p[j][0])**2 + (p[i][1] - p[j][1])**2) for i, j in itertools.combinations(list(range(N)), 2)) * np.math.factorial(N - 1) * 2 / np.math.factorial(N)))
from sys import stdin

#input = stdin.readlines

import math



def main():

    N = int(eval(input()))

    p = [list(map(int, input().split())) for _ in range(N)]

    s = 0.0

    for i in range(N - 1):

        for j in range(i + 1, N):

            s += math.sqrt((p[i][0] - p[j][0])**2 + (p[i][1] - p[j][1])**2)

    print((s*2/N))



if __name__ == '__main__':

    main()
import numpy as np
import itertools

N = int(eval(input()))
p = [list(map(int, input().split())) for _ in range(N)]
print(
    (
        sum(
            np.sqrt((p[i][0] - p[j][0]) ** 2 + (p[i][1] - p[j][1]) ** 2)
            for i, j in itertools.combinations(list(range(N)), 2)
        )
        * np.math.factorial(N - 1)
        * 2
        / np.math.factorial(N)
    )
)

from sys import stdin

# input = stdin.readlines
import math


def main():
    N = int(eval(input()))
    p = [list(map(int, input().split())) for _ in range(N)]
    s = 0.0
    for i in range(N - 1):
        for j in range(i + 1, N):
            s += math.sqrt((p[i][0] - p[j][0]) ** 2 + (p[i][1] - p[j][1]) ** 2)
    print((s * 2 / N))


if __name__ == "__main__":
    main()

-import numpy as np -import itertools +from sys import stdin -N = int(eval(input())) -p = [list(map(int, input().split())) for _ in range(N)] -print( -    ( -        sum( -            np.sqrt((p[i][0] - p[j][0]) ** 2 + (p[i][1] - p[j][1]) ** 2) -            for i, j in itertools.combinations(list(range(N)), 2) -        ) -        * np.math.factorial(N - 1) -        * 2 -        / np.math.factorial(N) -    ) -) +# input = stdin.readlines +import math + + +def main(): +    N = int(eval(input())) +    p = [list(map(int, input().split())) for _ in range(N)] +    s = 0.0 +    for i in range(N - 1): +        for j in range(i + 1, N): +            s += math.sqrt((p[i][0] - p[j][0]) ** 2 + (p[i][1] - p[j][1]) ** 2) +    print((s * 2 / N)) + + +if __name__ == "__main__": +    main()