White Rabbit#716

White Rabbit

1 second
64 megabytes
Very easy

In the distance, the sound of small feet could be heard. It was the White Rabbit returning. He was dressed smartly, holding a pair of kid gloves in one hand and a large fan in the other. As he ran, he muttered quietly:

– Oh dear, what will the Duchess say! She will be furious if I'm late! Simply furious! Stop, I need to stop and think, meditate...

The Rabbit drew dots in the sand with the fan — these represented the places he still needed to visit before meeting the Duchess. Then, every minute, he performed the following operations:

The Rabbit decided that as soon as he drew two points in the same location, he would "set some kind of limit for the rabbits" and dash off. The question is, how long will this drawing process continue? Or could it possibly go on indefinitely?

Input

The first line of the input contains an integer (1 \leq N \leq 1000). The next lines each contain two integers X_i, Y_i — the coordinates of the -th point. The coordinates do not exceed in absolute value. All points are distinct.

Output

Output a single number — the number of minutes the Rabbit will spend drawing. If the drawing process never ends, print 0.

Examples

Example 1

Loading
Loading