import java.security.KeyStore.TrustedCertificateEntry
import java.util
import java.util.regex.Pattern
import java.util.{ArrayList, Collections, Comparator, List => JList}

import scala.math._
import scala.collection.mutable
import scala.collection.mutable.{ArrayBuffer, ListBuffer}
import scala.util.{Failure, Success, Try}

object Main{
  val LINE_SEPARATOR = "\n"
  def main(args: Array[String]): Unit = {
    if (sys.env.getOrElse("TEST", "")=="1"){
      println(test());
    }else{
      val input=io.Source.stdin.getLines().mkString(LINE_SEPARATOR);
      println(solve(input).trim());
    }
  }

  def init (nRows: Int, nCols: Int, default: Int) = Array.tabulate(nRows,nCols)( (x,y) =>  default)

  def sortIgnoreCase1(list: JList[String]): JList[String] = {
    val r = new ArrayList[String](list)
    Collections.sort(r, new Comparator[String] {
      override def compare(o1: String, o2: String): Int = o1.compareToIgnoreCase(o2)
    })
    r
  }

  def solve(input: String): String = {
    val n = input.split(LINE_SEPARATOR).head.toInt
    val x = input.split(LINE_SEPARATOR).tail.map(_.split(" ").head.toDouble)
    val y = input.split(LINE_SEPARATOR).tail.map(_.split(" ").tail.head.toDouble)

    val d = (0 until n).combinations(2).map{comb =>
      val i = comb(0)
      val j = comb(1)
      (comb(0) -> comb(1)) -> sqrt((x(i)-x(j))*(x(i)-x(j)) + (y(i) - y(j))*(y(i) - y(j)))
    }.toMap
    val result = (0 until n).permutations.map{perm =>
      perm.sliding(2).map{pair =>
        d((min(pair(0), pair(1)), max(pair(0), pair(1))))
      }.sum
    }.sum / (0 until n).permutations.size
    result.toString
  }

  def divisors(n: Long): Vector[Long] = {
    val halfList = (1 to sqrt(n).toInt).toVector.filter(_ % n == 0).map(_.toLong)
    val reversedList = if (sqrt(n).floor == sqrt(n)) halfList.reverse.tail.map(n/_) else halfList.reverse.map(n/_)
    halfList ++ reversedList
  }

  def gcd(m: Long, n: Long): Long = n match {
    case 0 => m
    case _ => gcd(n, m % n)
  }
  def lcm(a: Long, b: Long): Long = a * b / gcd(a, b)

  val tests=List(
    """3
      |0 0
      |1 0
      |0 1""".stripMargin -> """2.2761423749
                                   |""".stripMargin,
    """2
      |-879 981
      |-866 890""".stripMargin -> """91.9238815543
                                        |""".stripMargin,
    """8
      |-406 10
      |512 859
      |494 362
      |-955 -475
      |128 553
      |-986 -885
      |763 77
      |449 310""".stripMargin -> """7641.9817824387"""
  )

  def test():String= {
    return tests.map{case (i,o)=>(i.trim(),o.trim())}
      .zipWithIndex.map{
      case ((input,outputExpect),i)=>{
        val output=solve(input).trim();
        s"test${i+1}:"+(if(output==outputExpect){
          "Passed"
        }else{
          s"Failed\nexpect:\n${outputExpect}\noutput:\n${output}"
        })
      }}
      .mkString("\n");
  }
}