#!/usr/bin/env ruby
info = gets.chomp.split(" ").map(&:to_i)
result = 0

info[0].times do
  nums = gets.chomp.split(" ").map(&:to_i)
  dst =Math.sqrt(nums[0]**2 + nums[1]**2)
  if dst <= info[1]
    result += 1
  end
end

puts result
