fac=Proc.new{|m|(1..m).to_a.inject(1){|f,i|f*i}}
com=Proc.new{|m,k|(k.zero?)?1:(m-k+1..m).inject(:*)/fac[k]}
n=gets.to_i
xy=[]
n.times{xy<<gets.split.map(&:to_i)}
s=0
xy.combination(2).each{|a,b|s+=Math.sqrt((a[0]-b[0])**2+(a[1]-b[1])**2)}
puts s*(n-1)/com[n,2]