import java.util.*;

class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		long D = sc.nextLong();
		int[] X = new int[N];
		int[] Y = new int[N];
		int c=0;
		double dista = 0;
		for(int i=0;i<N;++i){
			X[i] = sc.nextInt();
			Y[i] = sc.nextInt();
		}
		sc.close();
		for(int i=0;i<N;++i){
			dista = Math.pow(X[i], 2) + Math.pow(Y[i], 2);
			if (D * D >= dista) {
				c++;
			}
		}
		System.out.println(c);
	}
}
 import java.util.*; util.* java class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		long D = sc.nextLong();
		int[] X = new int[N];
		int[] Y = new int[N];
		int c=0;
		double dista = 0;
		for(int i=0;i<N;++i){
			X[i] = sc.nextInt();
			Y[i] = sc.nextInt();
		}
		sc.close();
		for(int i=0;i<N;++i){
			dista = Math.pow(X[i], 2) + Math.pow(Y[i], 2);
			if (D * D >= dista) {
				c++;
			}
		}
		System.out.println(c);
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		long D = sc.nextLong();
		int[] X = new int[N];
		int[] Y = new int[N];
		int c=0;
		double dista = 0;
		for(int i=0;i<N;++i){
			X[i] = sc.nextInt();
			Y[i] = sc.nextInt();
		}
		sc.close();
		for(int i=0;i<N;++i){
			dista = Math.pow(X[i], 2) + Math.pow(Y[i], 2);
			if (D * D >= dista) {
				c++;
			}
		}
		System.out.println(c);
	} main {
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		long D = sc.nextLong();
		int[] X = new int[N];
		int[] Y = new int[N];
		int c=0;
		double dista = 0;
		for(int i=0;i<N;++i){
			X[i] = sc.nextInt();
			Y[i] = sc.nextInt();
		}
		sc.close();
		for(int i=0;i<N;++i){
			dista = Math.pow(X[i], 2) + Math.pow(Y[i], 2);
			if (D * D >= dista) {
				c++;
			}
		}
		System.out.println(c);
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc long D = sc.nextLong(); D sc.nextLong() sc.nextLong sc int[] X = new int[N]; X new int[N] N int[] Y = new int[N]; Y new int[N] N int c=0; c 0 double dista = 0; dista 0 for(int i=0;i<N;++i){
			X[i] = sc.nextInt();
			Y[i] = sc.nextInt();
		} int i=0; int i=0; i 0 i<N i N ++i ++i i {
			X[i] = sc.nextInt();
			Y[i] = sc.nextInt();
		} {
			X[i] = sc.nextInt();
			Y[i] = sc.nextInt();
		} X[i] = sc.nextInt() X[i] X i sc.nextInt() sc.nextInt sc Y[i] = sc.nextInt() Y[i] Y i sc.nextInt() sc.nextInt sc sc.close() sc.close sc for(int i=0;i<N;++i){
			dista = Math.pow(X[i], 2) + Math.pow(Y[i], 2);
			if (D * D >= dista) {
				c++;
			}
		} int i=0; int i=0; i 0 i<N i N ++i ++i i {
			dista = Math.pow(X[i], 2) + Math.pow(Y[i], 2);
			if (D * D >= dista) {
				c++;
			}
		} {
			dista = Math.pow(X[i], 2) + Math.pow(Y[i], 2);
			if (D * D >= dista) {
				c++;
			}
		} dista = Math.pow(X[i], 2) + Math.pow(Y[i], 2) dista Math.pow(X[i], 2) + Math.pow(Y[i], 2) Math.pow(X[i], 2) Math.pow Math X[i] X i 2 Math.pow(Y[i], 2) Math.pow Math Y[i] Y i 2 if (D * D >= dista) {
				c++;
			} D * D >= dista D * D D D dista {
				c++;
			} c++ c System.out.println(c) System.out.println System.out System System.out c String[] args args
import java.util.*;

class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		long D = sc.nextLong();
		int[] X = new int[N];
		int[] Y = new int[N];
		int c=0;
		double dista = 0;
		for(int i=0;i<N;++i){
			X[i] = sc.nextInt();
			Y[i] = sc.nextInt();
		}
		sc.close();
		for(int i=0;i<N;++i){
			dista = Math.pow(X[i], 2) + Math.pow(Y[i], 2);
			if (D * D >= dista) {
				c++;
			}
		}
		System.out.println(c);
	}
}

