import math



def resolve():

    N, D = list(map(int, input().split()))



    ans = 0

    for _ in range(N):

        x, y = list(map(int, input().split()))

        dist = math.sqrt(x*x + y*y)

        if dist <= D:

            ans += 1

    print(ans)



if __name__ == "__main__":

    resolve()
import math



def resolve():

    N, D = list(map(int, input().split()))



    ans = 0

    for _ in range(N):

        x, y = list(map(int, input().split()))

        if x*x + y*y <= D*D:

            ans += 1

    print(ans)



if __name__ == "__main__":

    resolve()
import math


def resolve():
    N, D = list(map(int, input().split()))
    ans = 0
    for _ in range(N):
        x, y = list(map(int, input().split()))
        dist = math.sqrt(x * x + y * y)
        if dist <= D:
            ans += 1
    print(ans)


if __name__ == "__main__":
    resolve()

import math


def resolve():
    N, D = list(map(int, input().split()))
    ans = 0
    for _ in range(N):
        x, y = list(map(int, input().split()))
        if x * x + y * y <= D * D:
            ans += 1
    print(ans)


if __name__ == "__main__":
    resolve()

-        dist = math.sqrt(x * x + y * y) -        if dist <= D: +        if x * x + y * y <= D * D: