import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Scanner;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        B solver = new B();
        solver.solve(1, in, out);
        out.close();
    }

    static class B {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int N = Integer.parseInt(in.next());
            int D = Integer.parseInt(in.next());
            int cnt = 0;
            for (int i = 0; i < N; i++) {
                long X = Long.parseLong(in.next());
                long Y = Long.parseLong(in.next());
                if (Math.sqrt((X * X) + (Y * Y)) <= D)
                    cnt++;
            }
            out.println(cnt);
        }

    }
}
 import java.io.OutputStream; OutputStream java.io import java.io.IOException; IOException java.io import java.io.InputStream; InputStream java.io import java.io.PrintWriter; PrintWriter java.io import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        B solver = new B();
        solver.solve(1, in, out);
        out.close();
    }

    static class B {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int N = Integer.parseInt(in.next());
            int D = Integer.parseInt(in.next());
            int cnt = 0;
            for (int i = 0; i < N; i++) {
                long X = Long.parseLong(in.next());
                long Y = Long.parseLong(in.next());
                if (Math.sqrt((X * X) + (Y * Y)) <= D)
                    cnt++;
            }
            out.println(cnt);
        }

    }
} Main public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        B solver = new B();
        solver.solve(1, in, out);
        out.close();
    } main {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        B solver = new B();
        solver.solve(1, in, out);
        out.close();
    } InputStream inputStream = System.in; inputStream System.in System System.in OutputStream outputStream = System.out; outputStream System.out System System.out Scanner in = new Scanner(inputStream); in new Scanner(inputStream) PrintWriter out = new PrintWriter(outputStream); out new PrintWriter(outputStream) B solver = new B(); solver new B() solver.solve(1, in, out) solver.solve solver 1 in out out.close() out.close out String[] args args static class B {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int N = Integer.parseInt(in.next());
            int D = Integer.parseInt(in.next());
            int cnt = 0;
            for (int i = 0; i < N; i++) {
                long X = Long.parseLong(in.next());
                long Y = Long.parseLong(in.next());
                if (Math.sqrt((X * X) + (Y * Y)) <= D)
                    cnt++;
            }
            out.println(cnt);
        }

    } B public void solve(int testNumber, Scanner in, PrintWriter out) {
            int N = Integer.parseInt(in.next());
            int D = Integer.parseInt(in.next());
            int cnt = 0;
            for (int i = 0; i < N; i++) {
                long X = Long.parseLong(in.next());
                long Y = Long.parseLong(in.next());
                if (Math.sqrt((X * X) + (Y * Y)) <= D)
                    cnt++;
            }
            out.println(cnt);
        } solve {
            int N = Integer.parseInt(in.next());
            int D = Integer.parseInt(in.next());
            int cnt = 0;
            for (int i = 0; i < N; i++) {
                long X = Long.parseLong(in.next());
                long Y = Long.parseLong(in.next());
                if (Math.sqrt((X * X) + (Y * Y)) <= D)
                    cnt++;
            }
            out.println(cnt);
        } int N = Integer.parseInt(in.next()); N Integer.parseInt(in.next()) Integer.parseInt Integer in.next() in.next in int D = Integer.parseInt(in.next()); D Integer.parseInt(in.next()) Integer.parseInt Integer in.next() in.next in int cnt = 0; cnt 0 for (int i = 0; i < N; i++) {
                long X = Long.parseLong(in.next());
                long Y = Long.parseLong(in.next());
                if (Math.sqrt((X * X) + (Y * Y)) <= D)
                    cnt++;
            } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
                long X = Long.parseLong(in.next());
                long Y = Long.parseLong(in.next());
                if (Math.sqrt((X * X) + (Y * Y)) <= D)
                    cnt++;
            } {
                long X = Long.parseLong(in.next());
                long Y = Long.parseLong(in.next());
                if (Math.sqrt((X * X) + (Y * Y)) <= D)
                    cnt++;
            } long X = Long.parseLong(in.next()); X Long.parseLong(in.next()) Long.parseLong Long in.next() in.next in long Y = Long.parseLong(in.next()); Y Long.parseLong(in.next()) Long.parseLong Long in.next() in.next in if (Math.sqrt((X * X) + (Y * Y)) <= D)
                    cnt++; Math.sqrt((X * X) + (Y * Y)) <= D Math.sqrt((X * X) + (Y * Y)) Math.sqrt Math (X * X) + (Y * Y) (X * X) X X (Y * Y) Y Y D cnt++ cnt out.println(cnt) out.println out cnt int testNumber testNumber Scanner in in PrintWriter out out public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        B solver = new B();
        solver.solve(1, in, out);
        out.close();
    }

    static class B {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int N = Integer.parseInt(in.next());
            int D = Integer.parseInt(in.next());
            int cnt = 0;
            for (int i = 0; i < N; i++) {
                long X = Long.parseLong(in.next());
                long Y = Long.parseLong(in.next());
                if (Math.sqrt((X * X) + (Y * Y)) <= D)
                    cnt++;
            }
            out.println(cnt);
        }

    }
} public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        B solver = new B();
        solver.solve(1, in, out);
        out.close();
    }

    static class B {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int N = Integer.parseInt(in.next());
            int D = Integer.parseInt(in.next());
            int cnt = 0;
            for (int i = 0; i < N; i++) {
                long X = Long.parseLong(in.next());
                long Y = Long.parseLong(in.next());
                if (Math.sqrt((X * X) + (Y * Y)) <= D)
                    cnt++;
            }
            out.println(cnt);
        }

    }
} Main
import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Scanner;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        B solver = new B();
        solver.solve(1, in, out);
        out.close();
    }

    static class B {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int N = Integer.parseInt(in.next());
            int D = Integer.parseInt(in.next());
            int cnt = 0;
            for (int i = 0; i < N; i++) {
                long X = Long.parseLong(in.next());
                long Y = Long.parseLong(in.next());
                if (Math.sqrt((X * X) + (Y * Y)) <= D)
                    cnt++;
            }
            out.println(cnt);
        }

    }
}

