import java.util.Scanner;

class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt(), D = scanner.nextInt(),ans=0;
        for (int i = 0; i < N; i++) {
            long a = scanner.nextInt(), b = scanner.nextInt();
            double dist = Math.sqrt(a*a+b*b);
            if (dist<=D)ans++;
        }
        System.out.println(ans);
    }

} import java.util.Scanner; Scanner java.util class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt(), D = scanner.nextInt(),ans=0;
        for (int i = 0; i < N; i++) {
            long a = scanner.nextInt(), b = scanner.nextInt();
            double dist = Math.sqrt(a*a+b*b);
            if (dist<=D)ans++;
        }
        System.out.println(ans);
    }

} Main public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt(), D = scanner.nextInt(),ans=0;
        for (int i = 0; i < N; i++) {
            long a = scanner.nextInt(), b = scanner.nextInt();
            double dist = Math.sqrt(a*a+b*b);
            if (dist<=D)ans++;
        }
        System.out.println(ans);
    } main {
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt(), D = scanner.nextInt(),ans=0;
        for (int i = 0; i < N; i++) {
            long a = scanner.nextInt(), b = scanner.nextInt();
            double dist = Math.sqrt(a*a+b*b);
            if (dist<=D)ans++;
        }
        System.out.println(ans);
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int N = scanner.nextInt() N scanner.nextInt() scanner.nextInt scanner D = scanner.nextInt() D scanner.nextInt() scanner.nextInt scanner ans=0; ans 0 for (int i = 0; i < N; i++) {
            long a = scanner.nextInt(), b = scanner.nextInt();
            double dist = Math.sqrt(a*a+b*b);
            if (dist<=D)ans++;
        } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
            long a = scanner.nextInt(), b = scanner.nextInt();
            double dist = Math.sqrt(a*a+b*b);
            if (dist<=D)ans++;
        } {
            long a = scanner.nextInt(), b = scanner.nextInt();
            double dist = Math.sqrt(a*a+b*b);
            if (dist<=D)ans++;
        } long a = scanner.nextInt() a scanner.nextInt() scanner.nextInt scanner b = scanner.nextInt(); b scanner.nextInt() scanner.nextInt scanner double dist = Math.sqrt(a*a+b*b); dist Math.sqrt(a*a+b*b) Math.sqrt Math a*a+b*b a*a a a b*b b b if (dist<=D)ans++; dist<=D dist D ans++ ans System.out.println(ans) System.out.println System.out System System.out ans String[] args args
import java.util.Scanner;

class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt(), D = scanner.nextInt(),ans=0;
        for (int i = 0; i < N; i++) {
            long a = scanner.nextInt(), b = scanner.nextInt();
            double dist = Math.sqrt(a*a+b*b);
            if (dist<=D)ans++;
        }
        System.out.println(ans);
    }

}
