process.stdin.resume();
process.stdin.setEncoding('utf-8');
 
let inputString = '';
let currentLine = 0;
 
process.stdin.on('data', inputStdin => {
    inputString += inputStdin;
});
 
process.stdin.on('end', _ => {
    inputString = inputString.trim().split('\n').map(string => {
        return string.trim();
    });
    
    main();    
});
 
function readLine() {
    return inputString[currentLine++];
}

function main() {
    const [n, d] = readLine().split(/\s/).map(Number)
    const d2 = Math.pow(d, 2)
    result = 0
    for (let i = 0; i < n; i++) {
      const [x, y] = readLine().split(/\s/).map(Number)
      const _d2 = Math.pow(x, 2) + Math.pow(y, 2)
      if (_d2 <= d2) {
        result += 1
      }
    }
  console.log(result)
}