Farmer John's N cows stand at N distinct points of his pasture. A large round grain silo sits in the middle of the pasture. Cows on opposite sides of the silo cannot see each other because the silo blocks the view. Count the pairs of cows that can see each other.
Seen from above, the silo is a circle of radius R centered at the origin (0,0). Two cows can see each other when the segment joining them does not meet this circle, and cannot when it does.
No cow stands inside the circle or on it, and no line through two cows is tangent to the circle.
The first line has the number of cows N and the silo radius R (1≤N≤50000, 1≤R≤1000000).
Each of the next N lines has the coordinates x and y of one cow (−1000000≤x,y≤1000000). All input values are integers.
Print the number of pairs of cows that can see each other.
In the first example four cows stand at (0,10), (0,−10), (10,0) and (−10,0) around a silo of radius 5. There are six ways to pick two of the four cows, and the two pairs that face each other across the silo cannot see each other: (0,10) with (0,−10), and (10,0) with (−10,0). The other four pairs can see each other.