N = gets.to_i
V = N.times.to_a
C = N.times.map{ gets.split.map(&:to_i) }
D = Array.new(N){ Array.new(N, 0) }
Q = (1 .. N).inject(&:*)

V.combination(2) do |i,j|
  a, b = [i,j].map{|k| C[k] }
  d = Math.sqrt((a[0] - b[0]) ** 2 + (a[1] - b[1]) ** 2)
  D[i][j] = D[j][i] = d
end
t = V.permutation(N).inject(0.0) do |sum, path|
  sum + path.each_cons(2).inject(0.0){|s,(a,b)| s + D[a][b]}
end
puts t / Q
