import java.util.*;
import java.io.*;

public class Main {
	public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);
		
		int n = sc.nextInt();
		int d = sc.nextInt();
		int ans = 0;
		int[] x = new int[n];
		int[] y = new int[n];
		for(int i = 0; i < n; i++) {
			x[i] = sc.nextInt();
			y[i] = sc.nextInt();
		}
		long dsq = (long) d*d;
		for(int i = 0; i < n; i++) {
			int dx = Math.abs(x[i]);
			int dy = Math.abs(y[i]);
			long distance = (long)dx*dx + (long)dy*dy;
			if(distance <= dsq) {
				ans++;
			}
		}
		System.out.println(ans);
	}
} import java.util.*; util.* java import java.io.*; io.* java public class Main {
	public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);
		
		int n = sc.nextInt();
		int d = sc.nextInt();
		int ans = 0;
		int[] x = new int[n];
		int[] y = new int[n];
		for(int i = 0; i < n; i++) {
			x[i] = sc.nextInt();
			y[i] = sc.nextInt();
		}
		long dsq = (long) d*d;
		for(int i = 0; i < n; i++) {
			int dx = Math.abs(x[i]);
			int dy = Math.abs(y[i]);
			long distance = (long)dx*dx + (long)dy*dy;
			if(distance <= dsq) {
				ans++;
			}
		}
		System.out.println(ans);
	}
} Main public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);
		
		int n = sc.nextInt();
		int d = sc.nextInt();
		int ans = 0;
		int[] x = new int[n];
		int[] y = new int[n];
		for(int i = 0; i < n; i++) {
			x[i] = sc.nextInt();
			y[i] = sc.nextInt();
		}
		long dsq = (long) d*d;
		for(int i = 0; i < n; i++) {
			int dx = Math.abs(x[i]);
			int dy = Math.abs(y[i]);
			long distance = (long)dx*dx + (long)dy*dy;
			if(distance <= dsq) {
				ans++;
			}
		}
		System.out.println(ans);
	} main {
		Scanner sc = new Scanner(System.in);
		
		int n = sc.nextInt();
		int d = sc.nextInt();
		int ans = 0;
		int[] x = new int[n];
		int[] y = new int[n];
		for(int i = 0; i < n; i++) {
			x[i] = sc.nextInt();
			y[i] = sc.nextInt();
		}
		long dsq = (long) d*d;
		for(int i = 0; i < n; i++) {
			int dx = Math.abs(x[i]);
			int dy = Math.abs(y[i]);
			long distance = (long)dx*dx + (long)dy*dy;
			if(distance <= dsq) {
				ans++;
			}
		}
		System.out.println(ans);
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int d = sc.nextInt(); d sc.nextInt() sc.nextInt sc int ans = 0; ans 0 int[] x = new int[n]; x new int[n] n int[] y = new int[n]; y new int[n] n 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 long dsq = (long) d*d; dsq (long) d*d (long) d d for(int i = 0; i < n; i++) {
			int dx = Math.abs(x[i]);
			int dy = Math.abs(y[i]);
			long distance = (long)dx*dx + (long)dy*dy;
			if(distance <= dsq) {
				ans++;
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			int dx = Math.abs(x[i]);
			int dy = Math.abs(y[i]);
			long distance = (long)dx*dx + (long)dy*dy;
			if(distance <= dsq) {
				ans++;
			}
		} {
			int dx = Math.abs(x[i]);
			int dy = Math.abs(y[i]);
			long distance = (long)dx*dx + (long)dy*dy;
			if(distance <= dsq) {
				ans++;
			}
		} int dx = Math.abs(x[i]); dx Math.abs(x[i]) Math.abs Math x[i] x i int dy = Math.abs(y[i]); dy Math.abs(y[i]) Math.abs Math y[i] y i long distance = (long)dx*dx + (long)dy*dy; distance (long)dx*dx + (long)dy*dy (long)dx*dx (long)dx dx (long)dy*dy (long)dy dy if(distance <= dsq) {
				ans++;
			} distance <= dsq distance dsq {
				ans++;
			} ans++ ans 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) throws IOException {
		Scanner sc = new Scanner(System.in);
		
		int n = sc.nextInt();
		int d = sc.nextInt();
		int ans = 0;
		int[] x = new int[n];
		int[] y = new int[n];
		for(int i = 0; i < n; i++) {
			x[i] = sc.nextInt();
			y[i] = sc.nextInt();
		}
		long dsq = (long) d*d;
		for(int i = 0; i < n; i++) {
			int dx = Math.abs(x[i]);
			int dy = Math.abs(y[i]);
			long distance = (long)dx*dx + (long)dy*dy;
			if(distance <= dsq) {
				ans++;
			}
		}
		System.out.println(ans);
	}
} public class Main {
	public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);
		
		int n = sc.nextInt();
		int d = sc.nextInt();
		int ans = 0;
		int[] x = new int[n];
		int[] y = new int[n];
		for(int i = 0; i < n; i++) {
			x[i] = sc.nextInt();
			y[i] = sc.nextInt();
		}
		long dsq = (long) d*d;
		for(int i = 0; i < n; i++) {
			int dx = Math.abs(x[i]);
			int dy = Math.abs(y[i]);
			long distance = (long)dx*dx + (long)dy*dy;
			if(distance <= dsq) {
				ans++;
			}
		}
		System.out.println(ans);
	}
} Main
import java.util.*;
import java.io.*;

public class Main {
	public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);
		
		int n = sc.nextInt();
		int d = sc.nextInt();
		int ans = 0;
		int[] x = new int[n];
		int[] y = new int[n];
		for(int i = 0; i < n; i++) {
			x[i] = sc.nextInt();
			y[i] = sc.nextInt();
		}
		long dsq = (long) d*d;
		for(int i = 0; i < n; i++) {
			int dx = Math.abs(x[i]);
			int dy = Math.abs(y[i]);
			long distance = (long)dx*dx + (long)dy*dy;
			if(distance <= dsq) {
				ans++;
			}
		}
		System.out.println(ans);
	}
}
