n = gets.chomp.to_i
x = []
y = []
dis = []
n.times do |ni|
  dis[ni] = ni
  x[ni],y[ni] = gets.chomp.split.collect{ |item| item.to_i}
end
disxy = Hash.new(0.0)
n.times do |ni|
  n.times do |nii|
    disxy["#{ni}-#{nii}"] = Math.sqrt(((x[ni] - x[nii]) **2) + ((y[ni] - y[nii]) ** 2))
  end
end

arr = dis.permutation(n)
sum = 0.0
cnt = arr.size.to_f
arr.each do |one|
  onedis = 0.0
  (n-1).times do |ni|
    onedis += disxy["#{one[ni]}-#{one[ni+1]}"]
  end
  sum += onedis
end

puts sum/cnt
