func readInt() -> Int {
    Int(readLine()!)!
}
 
func readInts() -> [Int] {
    readLine()!.split(separator: " ").map { Int($0)! }
}
 
prefix operator *
prefix func * <T> (a: [T]) -> (T, T) {return (a[0], a[1])}
prefix func * <T> (a: [T]) -> (T, T, T) {return (a[0], a[1], a[2])}

func main() {
    let (n, d) = *readInts()

    let ans = (0..<n).map { _ in
        let (x, y) = *readInts()
        return x * x + y * y
    }.filter {
        $0 <= d * d
    }.count

    print(ans)
}

main()