import java.util.Scanner;

public class Main {
	public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        Main m = new Main(sc);
        m.show(m.solve());
        sc.close();
    }
    
	//フィールド
    Scanner sc;
    int N;
    int D;
    int[] X;
    int [] Y;
    
    //入力
    Main(Scanner sc) {
        this.sc = sc;
        this.N = sc.nextInt();
        this.D = sc.nextInt();
    }
    
    //解答処理
    private int solve() {
        int count = 0;
        this.X =new int[N];
        this.Y = new int[N];
        
        for (int i=0; i<N; i++) {
        	X[i] = sc.nextInt();
        	Y[i] = sc.nextInt();
        	double p = Math.pow(X[i], 2);
        	double q = Math.pow(Y[i], 2);
        	double distance = Math.sqrt(p + q);
        	if (distance <= D) {
        		count++;
        	}
        }
        
        return count;
    }
    
    //出力
    public void show(int answer) {
        System.out.println(answer);
    }

} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        Main m = new Main(sc);
        m.show(m.solve());
        sc.close();
    }
    
	//フィールド
    Scanner sc;
    int N;
    int D;
    int[] X;
    int [] Y;
    
    //入力
    Main(Scanner sc) {
        this.sc = sc;
        this.N = sc.nextInt();
        this.D = sc.nextInt();
    }
    
    //解答処理
    private int solve() {
        int count = 0;
        this.X =new int[N];
        this.Y = new int[N];
        
        for (int i=0; i<N; i++) {
        	X[i] = sc.nextInt();
        	Y[i] = sc.nextInt();
        	double p = Math.pow(X[i], 2);
        	double q = Math.pow(Y[i], 2);
        	double distance = Math.sqrt(p + q);
        	if (distance <= D) {
        		count++;
        	}
        }
        
        return count;
    }
    
    //出力
    public void show(int answer) {
        System.out.println(answer);
    }

} Main //フィールド
    Scanner sc; sc int N; N int D; D int[] X; X int [] Y; Y public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        Main m = new Main(sc);
        m.show(m.solve());
        sc.close();
    } main {
        Scanner sc = new Scanner(System.in);
        Main m = new Main(sc);
        m.show(m.solve());
        sc.close();
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) Main m = new Main(sc); m new Main(sc) m.show(m.solve()) m.show m m.solve() m.solve m sc.close() sc.close sc String[] args args //入力
    Main(Scanner sc) {
        this.sc = sc;
        this.N = sc.nextInt();
        this.D = sc.nextInt();
    } Main {
        this.sc = sc;
        this.N = sc.nextInt();
        this.D = sc.nextInt();
    } this.sc = sc this.sc this this.sc sc this.N = sc.nextInt() this.N this this.N sc.nextInt() sc.nextInt sc this.D = sc.nextInt() this.D this this.D sc.nextInt() sc.nextInt sc Scanner sc sc //解答処理
    private int solve() {
        int count = 0;
        this.X =new int[N];
        this.Y = new int[N];
        
        for (int i=0; i<N; i++) {
        	X[i] = sc.nextInt();
        	Y[i] = sc.nextInt();
        	double p = Math.pow(X[i], 2);
        	double q = Math.pow(Y[i], 2);
        	double distance = Math.sqrt(p + q);
        	if (distance <= D) {
        		count++;
        	}
        }
        
        return count;
    } solve {
        int count = 0;
        this.X =new int[N];
        this.Y = new int[N];
        
        for (int i=0; i<N; i++) {
        	X[i] = sc.nextInt();
        	Y[i] = sc.nextInt();
        	double p = Math.pow(X[i], 2);
        	double q = Math.pow(Y[i], 2);
        	double distance = Math.sqrt(p + q);
        	if (distance <= D) {
        		count++;
        	}
        }
        
        return count;
    } int count = 0; count 0 this.X =new int[N] this.X this this.X new int[N] N this.Y = new int[N] this.Y this this.Y new int[N] N for (int i=0; i<N; i++) {
        	X[i] = sc.nextInt();
        	Y[i] = sc.nextInt();
        	double p = Math.pow(X[i], 2);
        	double q = Math.pow(Y[i], 2);
        	double distance = Math.sqrt(p + q);
        	if (distance <= D) {
        		count++;
        	}
        } int i=0; int i=0; i 0 i<N i N i++ i++ i {
        	X[i] = sc.nextInt();
        	Y[i] = sc.nextInt();
        	double p = Math.pow(X[i], 2);
        	double q = Math.pow(Y[i], 2);
        	double distance = Math.sqrt(p + q);
        	if (distance <= D) {
        		count++;
        	}
        } {
        	X[i] = sc.nextInt();
        	Y[i] = sc.nextInt();
        	double p = Math.pow(X[i], 2);
        	double q = Math.pow(Y[i], 2);
        	double distance = Math.sqrt(p + q);
        	if (distance <= D) {
        		count++;
        	}
        } 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 double p = Math.pow(X[i], 2); p Math.pow(X[i], 2) Math.pow Math X[i] X i 2 double q = Math.pow(Y[i], 2); q Math.pow(Y[i], 2) Math.pow Math Y[i] Y i 2 double distance = Math.sqrt(p + q); distance Math.sqrt(p + q) Math.sqrt Math p + q p q if (distance <= D) {
        		count++;
        	} distance <= D distance D {
        		count++;
        	} count++ count return count; count //出力
    public void show(int answer) {
        System.out.println(answer);
    } show {
        System.out.println(answer);
    } System.out.println(answer) System.out.println System.out System System.out answer int answer answer public class Main {
	public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        Main m = new Main(sc);
        m.show(m.solve());
        sc.close();
    }
    
	//フィールド
    Scanner sc;
    int N;
    int D;
    int[] X;
    int [] Y;
    
    //入力
    Main(Scanner sc) {
        this.sc = sc;
        this.N = sc.nextInt();
        this.D = sc.nextInt();
    }
    
    //解答処理
    private int solve() {
        int count = 0;
        this.X =new int[N];
        this.Y = new int[N];
        
        for (int i=0; i<N; i++) {
        	X[i] = sc.nextInt();
        	Y[i] = sc.nextInt();
        	double p = Math.pow(X[i], 2);
        	double q = Math.pow(Y[i], 2);
        	double distance = Math.sqrt(p + q);
        	if (distance <= D) {
        		count++;
        	}
        }
        
        return count;
    }
    
    //出力
    public void show(int answer) {
        System.out.println(answer);
    }

} public class Main {
	public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        Main m = new Main(sc);
        m.show(m.solve());
        sc.close();
    }
    
	//フィールド
    Scanner sc;
    int N;
    int D;
    int[] X;
    int [] Y;
    
    //入力
    Main(Scanner sc) {
        this.sc = sc;
        this.N = sc.nextInt();
        this.D = sc.nextInt();
    }
    
    //解答処理
    private int solve() {
        int count = 0;
        this.X =new int[N];
        this.Y = new int[N];
        
        for (int i=0; i<N; i++) {
        	X[i] = sc.nextInt();
        	Y[i] = sc.nextInt();
        	double p = Math.pow(X[i], 2);
        	double q = Math.pow(Y[i], 2);
        	double distance = Math.sqrt(p + q);
        	if (distance <= D) {
        		count++;
        	}
        }
        
        return count;
    }
    
    //出力
    public void show(int answer) {
        System.out.println(answer);
    }

} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        Main m = new Main(sc);
        m.show(m.solve());
        sc.close();
    }
    
	//フィールド
    Scanner sc;
    int N;
    int D;
    int[] X;
    int [] Y;
    
    //入力
    Main(Scanner sc) {
        this.sc = sc;
        this.N = sc.nextInt();
        this.D = sc.nextInt();
    }
    
    //解答処理
    private int solve() {
        int count = 0;
        this.X =new int[N];
        this.Y = new int[N];
        
        for (int i=0; i<N; i++) {
        	X[i] = sc.nextInt();
        	Y[i] = sc.nextInt();
        	double p = Math.pow(X[i], 2);
        	double q = Math.pow(Y[i], 2);
        	double distance = Math.sqrt(p + q);
        	if (distance <= D) {
        		count++;
        	}
        }
        
        return count;
    }
    
    //出力
    public void show(int answer) {
        System.out.println(answer);
    }

}
