process.stdin.resume()
process.stdin.setEncoding('utf8')
var g_input = ''
process.stdin.on('data', function(chunk) {
    g_input += chunk
})
process.stdin.on('end', function() {
    main(g_input.split(/\r?\n/))
})
function main(input){
  let ans = 0
  //console.log(input)
  input[0] = input[0].split(' ')
  let D = input[0][1]
  for(let i=1;i<input.length;i++){
    input[i] = input[i].split(' ')
    let x = Number(input[i][0])
    let y = Number(input[i][1])
    let k = Math.sqrt(x**2 +y**2)
    //console.log(`${x} ${y} ${k}`)
    //console.log(`${D} ${k}`)
    
    if(k<=D)ans++
  }
  console.log(ans)
}