A telecom company is developing a GSM network in the city of Beijing.
There are
To simplify the placement of this antenna, the location will be determined
by picking 3 of the
The company plans to pick the 3 houses at random, so they want to compute the average number of houses that will be covered across all possible choices for the location of the antenna.
For example, suppose there are 4 houses,
If we choose the circle defined by
Your task is to compute the average number of houses covered by the signal, given the locations of the houses. The positions of the houses are given in terms of a 2-dimensional coordinate system in which all houses have integer coordinates. You are guaranteed that no three houses lie on the same line and no four of them lie on the same circle.
Input Specification
The first line of input contains a single positive integer
Output Specification
The output should contain a single real number, the average number of houses
that will be covered by the signal. The absolute error of the result should be
less than or equal to
Sample Input
4
0 2
4 4
0 0
2 0
Sample Output
3.500
Explanation for Sample Output
Constraints
- In
of the test cases, for , the coordinates of house are both integers such that . No three houses are located on a line and no four houses are located on a circle. - In
of the test cases, . - In
of the test cases, . - In
of the test cases, .
Comments
Just passed it in java by submitting 4 times. It would be really nice if java's time limit is set to 1.1 s