import 'dart:async';
import 'dart:io';
import 'dart:convert';
import 'dart:math';

Stream<String> get lineStream =>
    stdin.transform(utf8.decoder).transform(const LineSplitter());

Future<List<String>> readLines() async {
  final lines = <String>[];
  await for (var line in lineStream) {
    lines.add(line);
  }
  return lines;
}

void main() async {
  final lines = await readLines();
  final nd = lines[0].split(' ').map((e) => int.parse(e)).toList();
  var count = 0;
  for (var i = 0; i < nd[0]; i++) {
    final xy = lines[i + 1].split(' ').map((e) => int.parse(e)).toList();
    final d = sqrt(pow(xy[0], 2) + pow(xy[1], 2));
    if (d <= nd[1]) {
      count++;
    }
  }
  print('$count');
}