import java.util.*;
import java.io.*;
class Main{
	public static void main(String[]args){
		Scanner in=new Scanner(System.in);
		PrintWriter out = new PrintWriter(System.out, true);
		int n = in.nextInt();
		int d = in.nextInt();
		int count = 0;
		for(int i=0;i<n;i++){
			int x = in.nextInt();
			int y = in.nextInt();
			
			double distance = Math.sqrt(Math.pow(x, 2) + Math.pow(y, 2));
			if(distance <= d)
				count++;
		}
		out.println(count);
	}
} import java.util.*; util.* java import java.io.*; io.* java class Main{
	public static void main(String[]args){
		Scanner in=new Scanner(System.in);
		PrintWriter out = new PrintWriter(System.out, true);
		int n = in.nextInt();
		int d = in.nextInt();
		int count = 0;
		for(int i=0;i<n;i++){
			int x = in.nextInt();
			int y = in.nextInt();
			
			double distance = Math.sqrt(Math.pow(x, 2) + Math.pow(y, 2));
			if(distance <= d)
				count++;
		}
		out.println(count);
	}
} Main public static void main(String[]args){
		Scanner in=new Scanner(System.in);
		PrintWriter out = new PrintWriter(System.out, true);
		int n = in.nextInt();
		int d = in.nextInt();
		int count = 0;
		for(int i=0;i<n;i++){
			int x = in.nextInt();
			int y = in.nextInt();
			
			double distance = Math.sqrt(Math.pow(x, 2) + Math.pow(y, 2));
			if(distance <= d)
				count++;
		}
		out.println(count);
	} main {
		Scanner in=new Scanner(System.in);
		PrintWriter out = new PrintWriter(System.out, true);
		int n = in.nextInt();
		int d = in.nextInt();
		int count = 0;
		for(int i=0;i<n;i++){
			int x = in.nextInt();
			int y = in.nextInt();
			
			double distance = Math.sqrt(Math.pow(x, 2) + Math.pow(y, 2));
			if(distance <= d)
				count++;
		}
		out.println(count);
	} Scanner in=new Scanner(System.in); in new Scanner(System.in) PrintWriter out = new PrintWriter(System.out, true); out new PrintWriter(System.out, true) int n = in.nextInt(); n in.nextInt() in.nextInt in int d = in.nextInt(); d in.nextInt() in.nextInt in int count = 0; count 0 for(int i=0;i<n;i++){
			int x = in.nextInt();
			int y = in.nextInt();
			
			double distance = Math.sqrt(Math.pow(x, 2) + Math.pow(y, 2));
			if(distance <= d)
				count++;
		} int i=0; int i=0; i 0 i<n i n i++ i++ i {
			int x = in.nextInt();
			int y = in.nextInt();
			
			double distance = Math.sqrt(Math.pow(x, 2) + Math.pow(y, 2));
			if(distance <= d)
				count++;
		} {
			int x = in.nextInt();
			int y = in.nextInt();
			
			double distance = Math.sqrt(Math.pow(x, 2) + Math.pow(y, 2));
			if(distance <= d)
				count++;
		} int x = in.nextInt(); x in.nextInt() in.nextInt in int y = in.nextInt(); y in.nextInt() in.nextInt in double distance = Math.sqrt(Math.pow(x, 2) + Math.pow(y, 2)); distance Math.sqrt(Math.pow(x, 2) + Math.pow(y, 2)) Math.sqrt Math Math.pow(x, 2) + Math.pow(y, 2) Math.pow(x, 2) Math.pow Math x 2 Math.pow(y, 2) Math.pow Math y 2 if(distance <= d)
				count++; distance <= d distance d count++ count out.println(count) out.println out count String[]args args
import java.util.*;
import java.io.*;
class Main{
	public static void main(String[]args){
		Scanner in=new Scanner(System.in);
		PrintWriter out = new PrintWriter(System.out, true);
		int n = in.nextInt();
		int d = in.nextInt();
		int count = 0;
		for(int i=0;i<n;i++){
			int x = in.nextInt();
			int y = in.nextInt();
			
			double distance = Math.sqrt(Math.pow(x, 2) + Math.pow(y, 2));
			if(distance <= d)
				count++;
		}
		out.println(count);
	}
}
