import java.util.Arrays;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        long d = sc.nextLong();
        int kaunto = 0;
        long[] a = new long[n];
        long[] b = new long[n];
        for(int i = 0; i < n; i++){
            a[i] = sc.nextLong();
            b[i] = sc.nextLong();
            if(a[i]*a[i] + b[i]*b[i] <= d*d) kaunto++;
        }
        System.out.println(kaunto);
        sc.close();
    }
} import java.util.Arrays; Arrays java.util import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        long d = sc.nextLong();
        int kaunto = 0;
        long[] a = new long[n];
        long[] b = new long[n];
        for(int i = 0; i < n; i++){
            a[i] = sc.nextLong();
            b[i] = sc.nextLong();
            if(a[i]*a[i] + b[i]*b[i] <= d*d) kaunto++;
        }
        System.out.println(kaunto);
        sc.close();
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        long d = sc.nextLong();
        int kaunto = 0;
        long[] a = new long[n];
        long[] b = new long[n];
        for(int i = 0; i < n; i++){
            a[i] = sc.nextLong();
            b[i] = sc.nextLong();
            if(a[i]*a[i] + b[i]*b[i] <= d*d) kaunto++;
        }
        System.out.println(kaunto);
        sc.close();
    } main {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        long d = sc.nextLong();
        int kaunto = 0;
        long[] a = new long[n];
        long[] b = new long[n];
        for(int i = 0; i < n; i++){
            a[i] = sc.nextLong();
            b[i] = sc.nextLong();
            if(a[i]*a[i] + b[i]*b[i] <= d*d) kaunto++;
        }
        System.out.println(kaunto);
        sc.close();
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc long d = sc.nextLong(); d sc.nextLong() sc.nextLong sc int kaunto = 0; kaunto 0 long[] a = new long[n]; a new long[n] n long[] b = new long[n]; b new long[n] n for(int i = 0; i < n; i++){
            a[i] = sc.nextLong();
            b[i] = sc.nextLong();
            if(a[i]*a[i] + b[i]*b[i] <= d*d) kaunto++;
        } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
            a[i] = sc.nextLong();
            b[i] = sc.nextLong();
            if(a[i]*a[i] + b[i]*b[i] <= d*d) kaunto++;
        } {
            a[i] = sc.nextLong();
            b[i] = sc.nextLong();
            if(a[i]*a[i] + b[i]*b[i] <= d*d) kaunto++;
        } a[i] = sc.nextLong() a[i] a i sc.nextLong() sc.nextLong sc b[i] = sc.nextLong() b[i] b i sc.nextLong() sc.nextLong sc if(a[i]*a[i] + b[i]*b[i] <= d*d) kaunto++; a[i]*a[i] + b[i]*b[i] <= d*d a[i]*a[i] + b[i]*b[i] a[i]*a[i] a[i] a i a[i] a i b[i]*b[i] b[i] b i b[i] b i d*d d d kaunto++ kaunto System.out.println(kaunto) System.out.println System.out System System.out kaunto sc.close() sc.close sc String[] args args public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        long d = sc.nextLong();
        int kaunto = 0;
        long[] a = new long[n];
        long[] b = new long[n];
        for(int i = 0; i < n; i++){
            a[i] = sc.nextLong();
            b[i] = sc.nextLong();
            if(a[i]*a[i] + b[i]*b[i] <= d*d) kaunto++;
        }
        System.out.println(kaunto);
        sc.close();
    }
} public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        long d = sc.nextLong();
        int kaunto = 0;
        long[] a = new long[n];
        long[] b = new long[n];
        for(int i = 0; i < n; i++){
            a[i] = sc.nextLong();
            b[i] = sc.nextLong();
            if(a[i]*a[i] + b[i]*b[i] <= d*d) kaunto++;
        }
        System.out.println(kaunto);
        sc.close();
    }
} Main
import java.util.Arrays;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        long d = sc.nextLong();
        int kaunto = 0;
        long[] a = new long[n];
        long[] b = new long[n];
        for(int i = 0; i < n; i++){
            a[i] = sc.nextLong();
            b[i] = sc.nextLong();
            if(a[i]*a[i] + b[i]*b[i] <= d*d) kaunto++;
        }
        System.out.println(kaunto);
        sc.close();
    }
}