def resolve():
    N, D = map(int, input().split())

    cnt = 0
    for n in range(N):
        x, y = map(int, input().split())
        d = (x ** 2 + y ** 2) ** 0.5
        if d <= D:
            cnt += 1

    print(cnt)
resolve() def resolve():
    N, D = map(int, input().split())

    cnt = 0
    for n in range(N):
        x, y = map(int, input().split())
        d = (x ** 2 + y ** 2) ** 0.5
        if d <= D:
            cnt += 1

    print(cnt) resolve N, D = map(int, input().split()) N map(int, input().split()) map int input().split() ().split () input split D cnt = 0 cnt 0 for n in range(N):
        x, y = map(int, input().split())
        d = (x ** 2 + y ** 2) ** 0.5
        if d <= D:
            cnt += 1

     n range(N) range N x, y = map(int, input().split()) x map(int, input().split()) map int input().split() ().split () input split y d = (x ** 2 + y ** 2) ** 0.5 d (x ** 2 + y ** 2) ** 0.5 x ** 2 + y ** 2 x ** 2 x 2 y ** 2 y 2 0.5 if d <= D:
            cnt += 1

     d <= D d D cnt += 1 cnt 1 print(cnt) print cnt resolve() resolve def resolve():
    N, D = map(int, input().split())

    cnt = 0
    for n in range(N):
        x, y = map(int, input().split())
        d = (x ** 2 + y ** 2) ** 0.5
        if d <= D:
            cnt += 1

    print(cnt) def resolve():
    N, D = map(int, input().split())

    cnt = 0
    for n in range(N):
        x, y = map(int, input().split())
        d = (x ** 2 + y ** 2) ** 0.5
        if d <= D:
            cnt += 1

    print(cnt) resolve
def resolve():
    N, D = map(int, input().split())

    cnt = 0
    for n in range(N):
        x, y = map(int, input().split())
        d = (x ** 2 + y ** 2) ** 0.5
        if d <= D:
            cnt += 1

    print(cnt)
resolve()