
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.HashSet;

public class Main {
    public static void main(String[] args) throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String[] s=br.readLine().split(" ");
        int n=Integer.parseInt(s[0].trim());
        long d=Long.parseLong(s[1].trim());
        long r=(d*d);
        long res=0;

        for(int i=0;i<n;i++){
            s=br.readLine().split(" ");
            long x=Long.parseLong(s[0].trim());
            long y=Long.parseLong(s[1].trim());
            if(is_path(x,y,r)){
                res++;
            }

        }
System.out.println(res);
//        int t = Integer.parseInt(br.readLine().trim());

    }

    public static boolean is_path(long x,long y,long d){
        long r=(x*x)+(y*y);
//        r=Math.sqrt(r);
        if(r<=d){
            return true;
        }
        return false;
    }



} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io import java.util.HashSet; HashSet java.util public class Main {
    public static void main(String[] args) throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String[] s=br.readLine().split(" ");
        int n=Integer.parseInt(s[0].trim());
        long d=Long.parseLong(s[1].trim());
        long r=(d*d);
        long res=0;

        for(int i=0;i<n;i++){
            s=br.readLine().split(" ");
            long x=Long.parseLong(s[0].trim());
            long y=Long.parseLong(s[1].trim());
            if(is_path(x,y,r)){
                res++;
            }

        }
System.out.println(res);
//        int t = Integer.parseInt(br.readLine().trim());

    }

    public static boolean is_path(long x,long y,long d){
        long r=(x*x)+(y*y);
//        r=Math.sqrt(r);
        if(r<=d){
            return true;
        }
        return false;
    }



} Main public static void main(String[] args) throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String[] s=br.readLine().split(" ");
        int n=Integer.parseInt(s[0].trim());
        long d=Long.parseLong(s[1].trim());
        long r=(d*d);
        long res=0;

        for(int i=0;i<n;i++){
            s=br.readLine().split(" ");
            long x=Long.parseLong(s[0].trim());
            long y=Long.parseLong(s[1].trim());
            if(is_path(x,y,r)){
                res++;
            }

        }
System.out.println(res);
//        int t = Integer.parseInt(br.readLine().trim());

    } main {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String[] s=br.readLine().split(" ");
        int n=Integer.parseInt(s[0].trim());
        long d=Long.parseLong(s[1].trim());
        long r=(d*d);
        long res=0;

        for(int i=0;i<n;i++){
            s=br.readLine().split(" ");
            long x=Long.parseLong(s[0].trim());
            long y=Long.parseLong(s[1].trim());
            if(is_path(x,y,r)){
                res++;
            }

        }
System.out.println(res);
//        int t = Integer.parseInt(br.readLine().trim());

    } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) String[] s=br.readLine().split(" "); s br.readLine().split(" ") br.readLine().split br.readLine() br.readLine br " " int n=Integer.parseInt(s[0].trim()); n Integer.parseInt(s[0].trim()) Integer.parseInt Integer s[0].trim() s[0].trim s[0] s 0 long d=Long.parseLong(s[1].trim()); d Long.parseLong(s[1].trim()) Long.parseLong Long s[1].trim() s[1].trim s[1] s 1 long r=(d*d); r (d*d) d d long res=0; res 0 for(int i=0;i<n;i++){
            s=br.readLine().split(" ");
            long x=Long.parseLong(s[0].trim());
            long y=Long.parseLong(s[1].trim());
            if(is_path(x,y,r)){
                res++;
            }

        } int i=0; int i=0; i 0 i<n i n i++ i++ i {
            s=br.readLine().split(" ");
            long x=Long.parseLong(s[0].trim());
            long y=Long.parseLong(s[1].trim());
            if(is_path(x,y,r)){
                res++;
            }

        } {
            s=br.readLine().split(" ");
            long x=Long.parseLong(s[0].trim());
            long y=Long.parseLong(s[1].trim());
            if(is_path(x,y,r)){
                res++;
            }

        } s=br.readLine().split(" ") s br.readLine().split(" ") br.readLine().split br.readLine() br.readLine br " " long x=Long.parseLong(s[0].trim()); x Long.parseLong(s[0].trim()) Long.parseLong Long s[0].trim() s[0].trim s[0] s 0 long y=Long.parseLong(s[1].trim()); y Long.parseLong(s[1].trim()) Long.parseLong Long s[1].trim() s[1].trim s[1] s 1 if(is_path(x,y,r)){
                res++;
            } is_path(x,y,r) is_path x y r {
                res++;
            } res++ res System.out.println(res) System.out.println System.out System System.out res String[] args args public static boolean is_path(long x,long y,long d){
        long r=(x*x)+(y*y);
//        r=Math.sqrt(r);
        if(r<=d){
            return true;
        }
        return false;
    } is_path {
        long r=(x*x)+(y*y);
//        r=Math.sqrt(r);
        if(r<=d){
            return true;
        }
        return false;
    } long r=(x*x)+(y*y); r (x*x)+(y*y) (x*x) x x (y*y) y y if(r<=d){
            return true;
        } r<=d r d {
            return true;
        } return true; true return false; false long x x long y y long d d public class Main {
    public static void main(String[] args) throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String[] s=br.readLine().split(" ");
        int n=Integer.parseInt(s[0].trim());
        long d=Long.parseLong(s[1].trim());
        long r=(d*d);
        long res=0;

        for(int i=0;i<n;i++){
            s=br.readLine().split(" ");
            long x=Long.parseLong(s[0].trim());
            long y=Long.parseLong(s[1].trim());
            if(is_path(x,y,r)){
                res++;
            }

        }
System.out.println(res);
//        int t = Integer.parseInt(br.readLine().trim());

    }

    public static boolean is_path(long x,long y,long d){
        long r=(x*x)+(y*y);
//        r=Math.sqrt(r);
        if(r<=d){
            return true;
        }
        return false;
    }



} public class Main {
    public static void main(String[] args) throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String[] s=br.readLine().split(" ");
        int n=Integer.parseInt(s[0].trim());
        long d=Long.parseLong(s[1].trim());
        long r=(d*d);
        long res=0;

        for(int i=0;i<n;i++){
            s=br.readLine().split(" ");
            long x=Long.parseLong(s[0].trim());
            long y=Long.parseLong(s[1].trim());
            if(is_path(x,y,r)){
                res++;
            }

        }
System.out.println(res);
//        int t = Integer.parseInt(br.readLine().trim());

    }

    public static boolean is_path(long x,long y,long d){
        long r=(x*x)+(y*y);
//        r=Math.sqrt(r);
        if(r<=d){
            return true;
        }
        return false;
    }



} Main

import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.HashSet;

public class Main {
    public static void main(String[] args) throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String[] s=br.readLine().split(" ");
        int n=Integer.parseInt(s[0].trim());
        long d=Long.parseLong(s[1].trim());
        long r=(d*d);
        long res=0;

        for(int i=0;i<n;i++){
            s=br.readLine().split(" ");
            long x=Long.parseLong(s[0].trim());
            long y=Long.parseLong(s[1].trim());
            if(is_path(x,y,r)){
                res++;
            }

        }
System.out.println(res);
//        int t = Integer.parseInt(br.readLine().trim());

    }

    public static boolean is_path(long x,long y,long d){
        long r=(x*x)+(y*y);
//        r=Math.sqrt(r);
        if(r<=d){
            return true;
        }
        return false;
    }



}
