import java.io.*;
import java.util.*;
import static java.lang.System.out;

public class Main{
    public static void main(String[] args) throws Exception {
        BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
        int N;
        long D;
        {String[] a = in.readLine().split(" "); N = Integer.parseInt(a[0]); D = Long.parseLong(a[1]);}
        D *= D;
        int ans = 0;
        for (int i = 0; i < N; i++) {
            long x, y; {String[] a = in.readLine().split(" "); x = Long.parseLong(a[0]); y = Long.parseLong(a[1]);}
            long d = x * x + y * y;
            if (d <= D) {
                ans++;
            }
        }
        out.println(ans);
    }
} import java.io.*; io.* java import java.util.*; util.* java import static java.lang.System.out; import static java.lang.System.out; import static java.lang.System.out; public class Main{
    public static void main(String[] args) throws Exception {
        BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
        int N;
        long D;
        {String[] a = in.readLine().split(" "); N = Integer.parseInt(a[0]); D = Long.parseLong(a[1]);}
        D *= D;
        int ans = 0;
        for (int i = 0; i < N; i++) {
            long x, y; {String[] a = in.readLine().split(" "); x = Long.parseLong(a[0]); y = Long.parseLong(a[1]);}
            long d = x * x + y * y;
            if (d <= D) {
                ans++;
            }
        }
        out.println(ans);
    }
} Main public static void main(String[] args) throws Exception {
        BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
        int N;
        long D;
        {String[] a = in.readLine().split(" "); N = Integer.parseInt(a[0]); D = Long.parseLong(a[1]);}
        D *= D;
        int ans = 0;
        for (int i = 0; i < N; i++) {
            long x, y; {String[] a = in.readLine().split(" "); x = Long.parseLong(a[0]); y = Long.parseLong(a[1]);}
            long d = x * x + y * y;
            if (d <= D) {
                ans++;
            }
        }
        out.println(ans);
    } main {
        BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
        int N;
        long D;
        {String[] a = in.readLine().split(" "); N = Integer.parseInt(a[0]); D = Long.parseLong(a[1]);}
        D *= D;
        int ans = 0;
        for (int i = 0; i < N; i++) {
            long x, y; {String[] a = in.readLine().split(" "); x = Long.parseLong(a[0]); y = Long.parseLong(a[1]);}
            long d = x * x + y * y;
            if (d <= D) {
                ans++;
            }
        }
        out.println(ans);
    } BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); in new BufferedReader(new InputStreamReader(System.in)) int N; N long D; D {String[] a = in.readLine().split(" "); N = Integer.parseInt(a[0]); D = Long.parseLong(a[1]);} String[] a = in.readLine().split(" "); a in.readLine().split(" ") in.readLine().split in.readLine() in.readLine in " " N = Integer.parseInt(a[0]) N Integer.parseInt(a[0]) Integer.parseInt Integer a[0] a 0 D = Long.parseLong(a[1]) D Long.parseLong(a[1]) Long.parseLong Long a[1] a 1 D *= D D D int ans = 0; ans 0 for (int i = 0; i < N; i++) {
            long x, y; {String[] a = in.readLine().split(" "); x = Long.parseLong(a[0]); y = Long.parseLong(a[1]);}
            long d = x * x + y * y;
            if (d <= D) {
                ans++;
            }
        } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
            long x, y; {String[] a = in.readLine().split(" "); x = Long.parseLong(a[0]); y = Long.parseLong(a[1]);}
            long d = x * x + y * y;
            if (d <= D) {
                ans++;
            }
        } {
            long x, y; {String[] a = in.readLine().split(" "); x = Long.parseLong(a[0]); y = Long.parseLong(a[1]);}
            long d = x * x + y * y;
            if (d <= D) {
                ans++;
            }
        } long x x y; y {String[] a = in.readLine().split(" "); x = Long.parseLong(a[0]); y = Long.parseLong(a[1]);} String[] a = in.readLine().split(" "); a in.readLine().split(" ") in.readLine().split in.readLine() in.readLine in " " x = Long.parseLong(a[0]) x Long.parseLong(a[0]) Long.parseLong Long a[0] a 0 y = Long.parseLong(a[1]) y Long.parseLong(a[1]) Long.parseLong Long a[1] a 1 long d = x * x + y * y; d x * x + y * y x * x x x y * y y y if (d <= D) {
                ans++;
            } d <= D d D {
                ans++;
            } ans++ ans out.println(ans) out.println out ans String[] args args public class Main{
    public static void main(String[] args) throws Exception {
        BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
        int N;
        long D;
        {String[] a = in.readLine().split(" "); N = Integer.parseInt(a[0]); D = Long.parseLong(a[1]);}
        D *= D;
        int ans = 0;
        for (int i = 0; i < N; i++) {
            long x, y; {String[] a = in.readLine().split(" "); x = Long.parseLong(a[0]); y = Long.parseLong(a[1]);}
            long d = x * x + y * y;
            if (d <= D) {
                ans++;
            }
        }
        out.println(ans);
    }
} public class Main{
    public static void main(String[] args) throws Exception {
        BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
        int N;
        long D;
        {String[] a = in.readLine().split(" "); N = Integer.parseInt(a[0]); D = Long.parseLong(a[1]);}
        D *= D;
        int ans = 0;
        for (int i = 0; i < N; i++) {
            long x, y; {String[] a = in.readLine().split(" "); x = Long.parseLong(a[0]); y = Long.parseLong(a[1]);}
            long d = x * x + y * y;
            if (d <= D) {
                ans++;
            }
        }
        out.println(ans);
    }
} Main
import java.io.*;
import java.util.*;
import static java.lang.System.out;

public class Main{
    public static void main(String[] args) throws Exception {
        BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
        int N;
        long D;
        {String[] a = in.readLine().split(" "); N = Integer.parseInt(a[0]); D = Long.parseLong(a[1]);}
        D *= D;
        int ans = 0;
        for (int i = 0; i < N; i++) {
            long x, y; {String[] a = in.readLine().split(" "); x = Long.parseLong(a[0]); y = Long.parseLong(a[1]);}
            long d = x * x + y * y;
            if (d <= D) {
                ans++;
            }
        }
        out.println(ans);
    }
}
