const func2 = (input)=>{
let a = input.split("\n")
let b = a[0].split (" ")
a.shift();
//console.log (a)
let distance_origin = b [1]
let num = b [0]

cal(num,a,distance_origin);

}

const cal= (number, array,origin) =>{
  let output=0
  //numに応じて繰り返し実行。配列arrayから取り出した上で計算する。
  for(i=0; i<number;i++) {
   let target = array[i].split(" ").map( str => parseInt(str, 10));
  //console.log(target)
   let total = Math.sqrt(target[0]**2 + target[1]**2)
  // console.log(total)
   if(origin>=total){
     output ++
   }

}
console.log(output)
}



func2(require("fs").readFileSync("/dev/stdin", "utf8"))
