n = int(eval(input()))

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

import itertools as it

c,d = 0,0

for t in it.permutations(list(range(n))):

  c += 1

  for i in range(len(t)-1):

    d += ((ll[t[i+1]][1]-ll[t[i]][1])**2+(ll[t[i+1]][0]-ll[t[i]][0])**2)**.5

print((d/c))
n=int(eval(input()))

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

print((sum(((x-z)**2+(y-w)**2)**.5 for x,y in l for z,w in l)/n))
n = int(eval(input()))
ll = [list(map(int, input().split())) for _ in range(n)]
import itertools as it

c, d = 0, 0
for t in it.permutations(list(range(n))):
    c += 1
    for i in range(len(t) - 1):
        d += (
            (ll[t[i + 1]][1] - ll[t[i]][1]) ** 2 + (ll[t[i + 1]][0] - ll[t[i]][0]) ** 2
        ) ** 0.5
print((d / c))

n = int(eval(input()))
l = [list(map(int, input().split())) for _ in range(n)]
print((sum(((x - z) ** 2 + (y - w) ** 2) ** 0.5 for x, y in l for z, w in l) / n))

-ll = [list(map(int, input().split())) for _ in range(n)] -import itertools as it - -c, d = 0, 0 -for t in it.permutations(list(range(n))): -    c += 1 -    for i in range(len(t) - 1): -        d += ( -            (ll[t[i + 1]][1] - ll[t[i]][1]) ** 2 + (ll[t[i + 1]][0] - ll[t[i]][0]) ** 2 -        ) ** 0.5 -print((d / c)) +l = [list(map(int, input().split())) for _ in range(n)] +print((sum(((x - z) ** 2 + (y - w) ** 2) ** 0.5 for x, y in l for z, w in l) / n))