import java.util.*;
public class Main{
    public static void main(String args[]){
    Scanner sc = new Scanner(System.in);
   long n = sc.nextInt();
   long d = sc.nextInt();
   long res=0;
    while(n-->0) {
    long x = sc.nextInt();
    long y = sc.nextInt();
    //int res =0;
    double dis =  Math.sqrt(x*x+y*y);
    
   int dis1 = (int)Math.ceil(dis);
    if(d>=dis)
    res += 1;
     }
    System.out.println(res);
   
      //  System.out.println("Hello World");
}
} import java.util.*; util.* java public class Main{
    public static void main(String args[]){
    Scanner sc = new Scanner(System.in);
   long n = sc.nextInt();
   long d = sc.nextInt();
   long res=0;
    while(n-->0) {
    long x = sc.nextInt();
    long y = sc.nextInt();
    //int res =0;
    double dis =  Math.sqrt(x*x+y*y);
    
   int dis1 = (int)Math.ceil(dis);
    if(d>=dis)
    res += 1;
     }
    System.out.println(res);
   
      //  System.out.println("Hello World");
}
} Main public static void main(String args[]){
    Scanner sc = new Scanner(System.in);
   long n = sc.nextInt();
   long d = sc.nextInt();
   long res=0;
    while(n-->0) {
    long x = sc.nextInt();
    long y = sc.nextInt();
    //int res =0;
    double dis =  Math.sqrt(x*x+y*y);
    
   int dis1 = (int)Math.ceil(dis);
    if(d>=dis)
    res += 1;
     }
    System.out.println(res);
   
      //  System.out.println("Hello World");
} main {
    Scanner sc = new Scanner(System.in);
   long n = sc.nextInt();
   long d = sc.nextInt();
   long res=0;
    while(n-->0) {
    long x = sc.nextInt();
    long y = sc.nextInt();
    //int res =0;
    double dis =  Math.sqrt(x*x+y*y);
    
   int dis1 = (int)Math.ceil(dis);
    if(d>=dis)
    res += 1;
     }
    System.out.println(res);
   
      //  System.out.println("Hello World");
} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) long n = sc.nextInt(); n sc.nextInt() sc.nextInt sc long d = sc.nextInt(); d sc.nextInt() sc.nextInt sc long res=0; res 0 while(n-->0) {
    long x = sc.nextInt();
    long y = sc.nextInt();
    //int res =0;
    double dis =  Math.sqrt(x*x+y*y);
    
   int dis1 = (int)Math.ceil(dis);
    if(d>=dis)
    res += 1;
     } n-->0 n-- n 0 {
    long x = sc.nextInt();
    long y = sc.nextInt();
    //int res =0;
    double dis =  Math.sqrt(x*x+y*y);
    
   int dis1 = (int)Math.ceil(dis);
    if(d>=dis)
    res += 1;
     } long x = sc.nextInt(); x sc.nextInt() sc.nextInt sc long y = sc.nextInt(); y sc.nextInt() sc.nextInt sc double dis =  Math.sqrt(x*x+y*y); dis Math.sqrt(x*x+y*y) Math.sqrt Math x*x+y*y x*x x x y*y y y int dis1 = (int)Math.ceil(dis); dis1 (int)Math.ceil(dis) Math.ceil Math dis if(d>=dis)
    res += 1; d>=dis d dis res += 1 res 1 System.out.println(res) System.out.println System.out System System.out res String args[] args public class Main{
    public static void main(String args[]){
    Scanner sc = new Scanner(System.in);
   long n = sc.nextInt();
   long d = sc.nextInt();
   long res=0;
    while(n-->0) {
    long x = sc.nextInt();
    long y = sc.nextInt();
    //int res =0;
    double dis =  Math.sqrt(x*x+y*y);
    
   int dis1 = (int)Math.ceil(dis);
    if(d>=dis)
    res += 1;
     }
    System.out.println(res);
   
      //  System.out.println("Hello World");
}
} public class Main{
    public static void main(String args[]){
    Scanner sc = new Scanner(System.in);
   long n = sc.nextInt();
   long d = sc.nextInt();
   long res=0;
    while(n-->0) {
    long x = sc.nextInt();
    long y = sc.nextInt();
    //int res =0;
    double dis =  Math.sqrt(x*x+y*y);
    
   int dis1 = (int)Math.ceil(dis);
    if(d>=dis)
    res += 1;
     }
    System.out.println(res);
   
      //  System.out.println("Hello World");
}
} Main
import java.util.*;
public class Main{
    public static void main(String args[]){
    Scanner sc = new Scanner(System.in);
   long n = sc.nextInt();
   long d = sc.nextInt();
   long res=0;
    while(n-->0) {
    long x = sc.nextInt();
    long y = sc.nextInt();
    //int res =0;
    double dis =  Math.sqrt(x*x+y*y);
    
   int dis1 = (int)Math.ceil(dis);
    if(d>=dis)
    res += 1;
     }
    System.out.println(res);
   
      //  System.out.println("Hello World");
}
}
