import java.util.Scanner;

public class Main {
	public static void main(String[] args){



		try (Scanner scanner = new Scanner(System.in)) {

			long num = scanner.nextInt();
			
			long distance = scanner.nextInt();
			distance = distance * distance;
			
			
			long cnt = 0;
			
			for(long i = 0; i < num; i++) {
				long x = scanner.nextInt();
				long y = scanner.nextInt();
				
				if (x * x + y * y <= distance) {
					cnt++;
				}
			}

			System.out.println(cnt);
		}
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args){



		try (Scanner scanner = new Scanner(System.in)) {

			long num = scanner.nextInt();
			
			long distance = scanner.nextInt();
			distance = distance * distance;
			
			
			long cnt = 0;
			
			for(long i = 0; i < num; i++) {
				long x = scanner.nextInt();
				long y = scanner.nextInt();
				
				if (x * x + y * y <= distance) {
					cnt++;
				}
			}

			System.out.println(cnt);
		}
	}
} Main public static void main(String[] args){



		try (Scanner scanner = new Scanner(System.in)) {

			long num = scanner.nextInt();
			
			long distance = scanner.nextInt();
			distance = distance * distance;
			
			
			long cnt = 0;
			
			for(long i = 0; i < num; i++) {
				long x = scanner.nextInt();
				long y = scanner.nextInt();
				
				if (x * x + y * y <= distance) {
					cnt++;
				}
			}

			System.out.println(cnt);
		}
	} main {



		try (Scanner scanner = new Scanner(System.in)) {

			long num = scanner.nextInt();
			
			long distance = scanner.nextInt();
			distance = distance * distance;
			
			
			long cnt = 0;
			
			for(long i = 0; i < num; i++) {
				long x = scanner.nextInt();
				long y = scanner.nextInt();
				
				if (x * x + y * y <= distance) {
					cnt++;
				}
			}

			System.out.println(cnt);
		}
	} try (Scanner scanner = new Scanner(System.in)) {

			long num = scanner.nextInt();
			
			long distance = scanner.nextInt();
			distance = distance * distance;
			
			
			long cnt = 0;
			
			for(long i = 0; i < num; i++) {
				long x = scanner.nextInt();
				long y = scanner.nextInt();
				
				if (x * x + y * y <= distance) {
					cnt++;
				}
			}

			System.out.println(cnt);
		} {

			long num = scanner.nextInt();
			
			long distance = scanner.nextInt();
			distance = distance * distance;
			
			
			long cnt = 0;
			
			for(long i = 0; i < num; i++) {
				long x = scanner.nextInt();
				long y = scanner.nextInt();
				
				if (x * x + y * y <= distance) {
					cnt++;
				}
			}

			System.out.println(cnt);
		} Scanner scanner = new Scanner(System.in) Scanner scanner = new Scanner(System.in) new Scanner(System.in) long num = scanner.nextInt(); num scanner.nextInt() scanner.nextInt scanner long distance = scanner.nextInt(); distance scanner.nextInt() scanner.nextInt scanner distance = distance * distance distance distance * distance distance distance long cnt = 0; cnt 0 for(long i = 0; i < num; i++) {
				long x = scanner.nextInt();
				long y = scanner.nextInt();
				
				if (x * x + y * y <= distance) {
					cnt++;
				}
			} long i = 0; long i = 0; i 0 i < num i num i++ i++ i {
				long x = scanner.nextInt();
				long y = scanner.nextInt();
				
				if (x * x + y * y <= distance) {
					cnt++;
				}
			} {
				long x = scanner.nextInt();
				long y = scanner.nextInt();
				
				if (x * x + y * y <= distance) {
					cnt++;
				}
			} long x = scanner.nextInt(); x scanner.nextInt() scanner.nextInt scanner long y = scanner.nextInt(); y scanner.nextInt() scanner.nextInt scanner if (x * x + y * y <= distance) {
					cnt++;
				} x * x + y * y <= distance x * x + y * y x * x x x y * y y y distance {
					cnt++;
				} cnt++ cnt System.out.println(cnt) System.out.println System.out System System.out cnt String[] args args public class Main {
	public static void main(String[] args){



		try (Scanner scanner = new Scanner(System.in)) {

			long num = scanner.nextInt();
			
			long distance = scanner.nextInt();
			distance = distance * distance;
			
			
			long cnt = 0;
			
			for(long i = 0; i < num; i++) {
				long x = scanner.nextInt();
				long y = scanner.nextInt();
				
				if (x * x + y * y <= distance) {
					cnt++;
				}
			}

			System.out.println(cnt);
		}
	}
} public class Main {
	public static void main(String[] args){



		try (Scanner scanner = new Scanner(System.in)) {

			long num = scanner.nextInt();
			
			long distance = scanner.nextInt();
			distance = distance * distance;
			
			
			long cnt = 0;
			
			for(long i = 0; i < num; i++) {
				long x = scanner.nextInt();
				long y = scanner.nextInt();
				
				if (x * x + y * y <= distance) {
					cnt++;
				}
			}

			System.out.println(cnt);
		}
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args){



		try (Scanner scanner = new Scanner(System.in)) {

			long num = scanner.nextInt();
			
			long distance = scanner.nextInt();
			distance = distance * distance;
			
			
			long cnt = 0;
			
			for(long i = 0; i < num; i++) {
				long x = scanner.nextInt();
				long y = scanner.nextInt();
				
				if (x * x + y * y <= distance) {
					cnt++;
				}
			}

			System.out.println(cnt);
		}
	}
}