Care for a chat?#3606

Care for a chat?

1 second
64 megabytes
Very easy

The opening ceremony of the Olympics was a spectacular event, lasting nearly hours. Everyone in attendance was enthralled by the performances, with many, including UN Secretary-General Ban Ki-moon, capturing memorable moments on their mobile phones.

During the Olympics, spectators naturally wanted to connect with each other using their mobile phones. However, they faced a challenge: they could only communicate if they were less than miles from each other. We won't delve into the technical reasons for this limitation in London, as our task is different: given the coordinates of spectators, we need to determine how many unique pairs of spectators could communicate with each other.

Keep in mind that the London coordinate system is measured in miles, and that the pairs and are considered identical.

Input

The first line contains numbers: the number of spectators (1 \leq N \leq 100) and the communication range (1 \leq R \leq 1000). The following lines each contain numbers, representing the coordinates of each spectator. All coordinates are integers with an absolute value not exceeding .

Output

Output a single number, which is the answer to the problem.

Examples

Example 1

Loading
Loading