

import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		long d = scan.nextInt();
		int count = 0;
		for(int i = 0; i < n; i++) {
			long x = scan.nextLong();
			long y = scan.nextLong();
			long xx;
			long yy;
			xx = (long)Math.pow(x,2);
			yy = (long)Math.pow(y,2);

			if(d>=Math.sqrt(xx+yy)) {
				count = count + 1;
			}
		}
		System.out.println(count);
	}

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

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		long d = scan.nextInt();
		int count = 0;
		for(int i = 0; i < n; i++) {
			long x = scan.nextLong();
			long y = scan.nextLong();
			long xx;
			long yy;
			xx = (long)Math.pow(x,2);
			yy = (long)Math.pow(y,2);

			if(d>=Math.sqrt(xx+yy)) {
				count = count + 1;
			}
		}
		System.out.println(count);
	}

} Main public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		long d = scan.nextInt();
		int count = 0;
		for(int i = 0; i < n; i++) {
			long x = scan.nextLong();
			long y = scan.nextLong();
			long xx;
			long yy;
			xx = (long)Math.pow(x,2);
			yy = (long)Math.pow(y,2);

			if(d>=Math.sqrt(xx+yy)) {
				count = count + 1;
			}
		}
		System.out.println(count);
	} main {
		// TODO 自動生成されたメソッド・スタブ
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		long d = scan.nextInt();
		int count = 0;
		for(int i = 0; i < n; i++) {
			long x = scan.nextLong();
			long y = scan.nextLong();
			long xx;
			long yy;
			xx = (long)Math.pow(x,2);
			yy = (long)Math.pow(y,2);

			if(d>=Math.sqrt(xx+yy)) {
				count = count + 1;
			}
		}
		System.out.println(count);
	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int n = scan.nextInt(); n scan.nextInt() scan.nextInt scan long d = scan.nextInt(); d scan.nextInt() scan.nextInt scan int count = 0; count 0 for(int i = 0; i < n; i++) {
			long x = scan.nextLong();
			long y = scan.nextLong();
			long xx;
			long yy;
			xx = (long)Math.pow(x,2);
			yy = (long)Math.pow(y,2);

			if(d>=Math.sqrt(xx+yy)) {
				count = count + 1;
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			long x = scan.nextLong();
			long y = scan.nextLong();
			long xx;
			long yy;
			xx = (long)Math.pow(x,2);
			yy = (long)Math.pow(y,2);

			if(d>=Math.sqrt(xx+yy)) {
				count = count + 1;
			}
		} {
			long x = scan.nextLong();
			long y = scan.nextLong();
			long xx;
			long yy;
			xx = (long)Math.pow(x,2);
			yy = (long)Math.pow(y,2);

			if(d>=Math.sqrt(xx+yy)) {
				count = count + 1;
			}
		} long x = scan.nextLong(); x scan.nextLong() scan.nextLong scan long y = scan.nextLong(); y scan.nextLong() scan.nextLong scan long xx; xx long yy; yy xx = (long)Math.pow(x,2) xx (long)Math.pow(x,2) Math.pow Math x 2 yy = (long)Math.pow(y,2) yy (long)Math.pow(y,2) Math.pow Math y 2 if(d>=Math.sqrt(xx+yy)) {
				count = count + 1;
			} d>=Math.sqrt(xx+yy) d Math.sqrt(xx+yy) Math.sqrt Math xx+yy xx yy {
				count = count + 1;
			} count = count + 1 count count + 1 count 1 System.out.println(count) System.out.println System.out System System.out count String[] args args public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		long d = scan.nextInt();
		int count = 0;
		for(int i = 0; i < n; i++) {
			long x = scan.nextLong();
			long y = scan.nextLong();
			long xx;
			long yy;
			xx = (long)Math.pow(x,2);
			yy = (long)Math.pow(y,2);

			if(d>=Math.sqrt(xx+yy)) {
				count = count + 1;
			}
		}
		System.out.println(count);
	}

} public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		long d = scan.nextInt();
		int count = 0;
		for(int i = 0; i < n; i++) {
			long x = scan.nextLong();
			long y = scan.nextLong();
			long xx;
			long yy;
			xx = (long)Math.pow(x,2);
			yy = (long)Math.pow(y,2);

			if(d>=Math.sqrt(xx+yy)) {
				count = count + 1;
			}
		}
		System.out.println(count);
	}

} Main


import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		long d = scan.nextInt();
		int count = 0;
		for(int i = 0; i < n; i++) {
			long x = scan.nextLong();
			long y = scan.nextLong();
			long xx;
			long yy;
			xx = (long)Math.pow(x,2);
			yy = (long)Math.pow(y,2);

			if(d>=Math.sqrt(xx+yy)) {
				count = count + 1;
			}
		}
		System.out.println(count);
	}

}
