n = gets.to_i

cities = []

n.times do
  x, y = gets.split.map(&:to_i) 
  cities << [x, y]
end

routes = cities.permutation.to_a
sum = 0.0
routes.each do |route|
  pos = route[0]
  route[1..-1].each do |to|
    diff = Math.sqrt(
      (pos[0] - to[0])**2 +
      (pos[1] - to[1])**2
    )
    pos = to
    sum += diff
  end
end

puts sum / routes.size