Crossing
Points
On his 6th anniversary, little Gigel has received a
convex polygon with N vertices. Not
knowing what to do with it, he started drawing lines between any two
non-adjacent vertices. After he painted all the possible lines, he noticed that
any 3 lines do not cross in the same point. Being a curious person, he would like
to know the number of different crossing points which lie inside the polygon (the
vertices of the polygon do not count as crossing points).
Input
Data
The input file POINTS.IN contains the
number N of vertices of the polygon.
Output
Data
The output file POINTS.OUT will
contaim the number of crossing points.
Limits
·
3 <= N <= 65535
Examples:
POINTS.IN POINTS.OUT
3 0
POINTS.IN POINTS.OUT
4 1
POINTS.IN POINTS.OUT
5 5
Time limit: 0.25
seconds/test case