let inp = readLine()!.split(separator: " ").map { Int($0)! }

let n = inp[0]
let d = inp[1]

var count = 0

for _ in 0..<n {
  let inputs = readLine()!.split(separator: " ").map { Int($0)! }
  let x = inputs[0]
  let y = inputs[1]
  
  if x * x + y * y <= d * d {
    count += 1
  }
}

print(count)