n, d = gets.chomp.split.map(&:to_i)
d = d * d
hash = {}
cnt = 0
n.times do |i|
	x, y = gets.chomp.split.map(&:to_i)
	# # #if d <= x ** 2 + y **2 && !hash.has_key?(x.to_s+"_"+y.to_s)
	# # 	cnt += 1
	# # 	hash[x.to_s+"_"+y.to_s] = 1
	# # end
	if d >= x *x +y * y
		cnt += 1
		#puts "x:#{x} y:#{y}"
	end
end
puts cnt
