def main():

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

if __name__ == '__main__':
    print(main()) def main():

    N, D = map(int, input().split())
    ans = 0
    for _ in range(N):
        x, y = map(int, input().split())
        if x*x + y* y <= D*D:
            ans += 1
    return ans main N, D = map(int, input().split()) N map(int, input().split()) map int input().split() ().split () input split D ans = 0 ans 0 for _ in range(N):
        x, y = map(int, input().split())
        if x*x + y* y <= D*D:
            ans += 1
     _ range(N) range N x, y = map(int, input().split()) x map(int, input().split()) map int input().split() ().split () input split y if x*x + y* y <= D*D:
            ans += 1
     x*x + y* y <= D*D x*x + y* y x*x x x y* y y y D*D D D ans += 1 ans 1 return ans ans if __name__ == '__main__':
    print(main()) __name__ == '__main__' __name__ '__main__' print(main()) print main() main def main():

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

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

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

if __name__ == '__main__':
    print(main())
