import java.util.Scanner;
public class Main {

	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int N = Integer.parseInt(scan.next());
		int D = Integer.parseInt(scan.next());
		int[] X = new int[N];
		int[] Y = new int[N];
		int ans = 0;
		for (int n = 0;n < N ;n++ ) {
			X[n] = Integer.parseInt(scan.next());
			Y[n] = Integer.parseInt(scan.next());
			long xx = (long)Math.pow(X[n], 2);
			long yy = (long)Math.pow(Y[n], 2);
			if (Math.sqrt(xx + yy) <= D) {
				ans++;
			}
		}
		scan.close();
		System.out.println(ans);
	}

} import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int N = Integer.parseInt(scan.next());
		int D = Integer.parseInt(scan.next());
		int[] X = new int[N];
		int[] Y = new int[N];
		int ans = 0;
		for (int n = 0;n < N ;n++ ) {
			X[n] = Integer.parseInt(scan.next());
			Y[n] = Integer.parseInt(scan.next());
			long xx = (long)Math.pow(X[n], 2);
			long yy = (long)Math.pow(Y[n], 2);
			if (Math.sqrt(xx + yy) <= D) {
				ans++;
			}
		}
		scan.close();
		System.out.println(ans);
	}

} Main public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int N = Integer.parseInt(scan.next());
		int D = Integer.parseInt(scan.next());
		int[] X = new int[N];
		int[] Y = new int[N];
		int ans = 0;
		for (int n = 0;n < N ;n++ ) {
			X[n] = Integer.parseInt(scan.next());
			Y[n] = Integer.parseInt(scan.next());
			long xx = (long)Math.pow(X[n], 2);
			long yy = (long)Math.pow(Y[n], 2);
			if (Math.sqrt(xx + yy) <= D) {
				ans++;
			}
		}
		scan.close();
		System.out.println(ans);
	} main {
		Scanner scan = new Scanner(System.in);
		int N = Integer.parseInt(scan.next());
		int D = Integer.parseInt(scan.next());
		int[] X = new int[N];
		int[] Y = new int[N];
		int ans = 0;
		for (int n = 0;n < N ;n++ ) {
			X[n] = Integer.parseInt(scan.next());
			Y[n] = Integer.parseInt(scan.next());
			long xx = (long)Math.pow(X[n], 2);
			long yy = (long)Math.pow(Y[n], 2);
			if (Math.sqrt(xx + yy) <= D) {
				ans++;
			}
		}
		scan.close();
		System.out.println(ans);
	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int N = Integer.parseInt(scan.next()); N Integer.parseInt(scan.next()) Integer.parseInt Integer scan.next() scan.next scan int D = Integer.parseInt(scan.next()); D Integer.parseInt(scan.next()) Integer.parseInt Integer scan.next() scan.next scan int[] X = new int[N]; X new int[N] N int[] Y = new int[N]; Y new int[N] N int ans = 0; ans 0 for (int n = 0;n < N ;n++ ) {
			X[n] = Integer.parseInt(scan.next());
			Y[n] = Integer.parseInt(scan.next());
			long xx = (long)Math.pow(X[n], 2);
			long yy = (long)Math.pow(Y[n], 2);
			if (Math.sqrt(xx + yy) <= D) {
				ans++;
			}
		} int n = 0; int n = 0; n 0 n < N n N n++ n++ n {
			X[n] = Integer.parseInt(scan.next());
			Y[n] = Integer.parseInt(scan.next());
			long xx = (long)Math.pow(X[n], 2);
			long yy = (long)Math.pow(Y[n], 2);
			if (Math.sqrt(xx + yy) <= D) {
				ans++;
			}
		} {
			X[n] = Integer.parseInt(scan.next());
			Y[n] = Integer.parseInt(scan.next());
			long xx = (long)Math.pow(X[n], 2);
			long yy = (long)Math.pow(Y[n], 2);
			if (Math.sqrt(xx + yy) <= D) {
				ans++;
			}
		} X[n] = Integer.parseInt(scan.next()) X[n] X n Integer.parseInt(scan.next()) Integer.parseInt Integer scan.next() scan.next scan Y[n] = Integer.parseInt(scan.next()) Y[n] Y n Integer.parseInt(scan.next()) Integer.parseInt Integer scan.next() scan.next scan long xx = (long)Math.pow(X[n], 2); xx (long)Math.pow(X[n], 2) Math.pow Math X[n] X n 2 long yy = (long)Math.pow(Y[n], 2); yy (long)Math.pow(Y[n], 2) Math.pow Math Y[n] Y n 2 if (Math.sqrt(xx + yy) <= D) {
				ans++;
			} Math.sqrt(xx + yy) <= D Math.sqrt(xx + yy) Math.sqrt Math xx + yy xx yy D {
				ans++;
			} ans++ ans scan.close() scan.close scan System.out.println(ans) System.out.println System.out System System.out ans String[] args args public class Main {

	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int N = Integer.parseInt(scan.next());
		int D = Integer.parseInt(scan.next());
		int[] X = new int[N];
		int[] Y = new int[N];
		int ans = 0;
		for (int n = 0;n < N ;n++ ) {
			X[n] = Integer.parseInt(scan.next());
			Y[n] = Integer.parseInt(scan.next());
			long xx = (long)Math.pow(X[n], 2);
			long yy = (long)Math.pow(Y[n], 2);
			if (Math.sqrt(xx + yy) <= D) {
				ans++;
			}
		}
		scan.close();
		System.out.println(ans);
	}

} public class Main {

	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int N = Integer.parseInt(scan.next());
		int D = Integer.parseInt(scan.next());
		int[] X = new int[N];
		int[] Y = new int[N];
		int ans = 0;
		for (int n = 0;n < N ;n++ ) {
			X[n] = Integer.parseInt(scan.next());
			Y[n] = Integer.parseInt(scan.next());
			long xx = (long)Math.pow(X[n], 2);
			long yy = (long)Math.pow(Y[n], 2);
			if (Math.sqrt(xx + yy) <= D) {
				ans++;
			}
		}
		scan.close();
		System.out.println(ans);
	}

} Main
import java.util.Scanner;
public class Main {

	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int N = Integer.parseInt(scan.next());
		int D = Integer.parseInt(scan.next());
		int[] X = new int[N];
		int[] Y = new int[N];
		int ans = 0;
		for (int n = 0;n < N ;n++ ) {
			X[n] = Integer.parseInt(scan.next());
			Y[n] = Integer.parseInt(scan.next());
			long xx = (long)Math.pow(X[n], 2);
			long yy = (long)Math.pow(Y[n], 2);
			if (Math.sqrt(xx + yy) <= D) {
				ans++;
			}
		}
		scan.close();
		System.out.println(ans);
	}

}
