import java.util.Scanner;

class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = Integer.parseInt(sc.next());
		int D = Integer.parseInt(sc.next());
		int count = 0;
		for(int i=0;i < N;i++) {
			long x = Long.parseLong(sc.next());
			long y = Long.parseLong(sc.next());
			if(Math.sqrt(x*x+y*y) <= D) {
				count++;
			}
		}
		System.out.println(count);
	}
}
 import java.util.Scanner; Scanner java.util class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = Integer.parseInt(sc.next());
		int D = Integer.parseInt(sc.next());
		int count = 0;
		for(int i=0;i < N;i++) {
			long x = Long.parseLong(sc.next());
			long y = Long.parseLong(sc.next());
			if(Math.sqrt(x*x+y*y) <= D) {
				count++;
			}
		}
		System.out.println(count);
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = Integer.parseInt(sc.next());
		int D = Integer.parseInt(sc.next());
		int count = 0;
		for(int i=0;i < N;i++) {
			long x = Long.parseLong(sc.next());
			long y = Long.parseLong(sc.next());
			if(Math.sqrt(x*x+y*y) <= D) {
				count++;
			}
		}
		System.out.println(count);
	} main {
		Scanner sc = new Scanner(System.in);
		int N = Integer.parseInt(sc.next());
		int D = Integer.parseInt(sc.next());
		int count = 0;
		for(int i=0;i < N;i++) {
			long x = Long.parseLong(sc.next());
			long y = Long.parseLong(sc.next());
			if(Math.sqrt(x*x+y*y) <= D) {
				count++;
			}
		}
		System.out.println(count);
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = Integer.parseInt(sc.next()); N Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc int D = Integer.parseInt(sc.next()); D Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc int count = 0; count 0 for(int i=0;i < N;i++) {
			long x = Long.parseLong(sc.next());
			long y = Long.parseLong(sc.next());
			if(Math.sqrt(x*x+y*y) <= D) {
				count++;
			}
		} int i=0; int i=0; i 0 i < N i N i++ i++ i {
			long x = Long.parseLong(sc.next());
			long y = Long.parseLong(sc.next());
			if(Math.sqrt(x*x+y*y) <= D) {
				count++;
			}
		} {
			long x = Long.parseLong(sc.next());
			long y = Long.parseLong(sc.next());
			if(Math.sqrt(x*x+y*y) <= D) {
				count++;
			}
		} long x = Long.parseLong(sc.next()); x Long.parseLong(sc.next()) Long.parseLong Long sc.next() sc.next sc long y = Long.parseLong(sc.next()); y Long.parseLong(sc.next()) Long.parseLong Long sc.next() sc.next sc if(Math.sqrt(x*x+y*y) <= D) {
				count++;
			} Math.sqrt(x*x+y*y) <= D Math.sqrt(x*x+y*y) Math.sqrt Math x*x+y*y x*x x x y*y y y D {
				count++;
			} count++ count System.out.println(count) System.out.println System.out System System.out count String[] args args
import java.util.Scanner;

class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = Integer.parseInt(sc.next());
		int D = Integer.parseInt(sc.next());
		int count = 0;
		for(int i=0;i < N;i++) {
			long x = Long.parseLong(sc.next());
			long y = Long.parseLong(sc.next());
			if(Math.sqrt(x*x+y*y) <= D) {
				count++;
			}
		}
		System.out.println(count);
	}
}

