import java.util.Scanner;
class Main {
  static public void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    long d = sc.nextLong();
    int a = 0;
    for (int i = 1; i <= n; i++) {
      long x = sc.nextLong();
      long y = sc.nextLong();
      if ((d*d) >= (x*x + y*y)) {
        a++;
      }
    }
    System.out.println(a);
  }
} import java.util.Scanner; Scanner java.util class Main {
  static public void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    long d = sc.nextLong();
    int a = 0;
    for (int i = 1; i <= n; i++) {
      long x = sc.nextLong();
      long y = sc.nextLong();
      if ((d*d) >= (x*x + y*y)) {
        a++;
      }
    }
    System.out.println(a);
  }
} Main static public void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    long d = sc.nextLong();
    int a = 0;
    for (int i = 1; i <= n; i++) {
      long x = sc.nextLong();
      long y = sc.nextLong();
      if ((d*d) >= (x*x + y*y)) {
        a++;
      }
    }
    System.out.println(a);
  } main {
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    long d = sc.nextLong();
    int a = 0;
    for (int i = 1; i <= n; i++) {
      long x = sc.nextLong();
      long y = sc.nextLong();
      if ((d*d) >= (x*x + y*y)) {
        a++;
      }
    }
    System.out.println(a);
  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc long d = sc.nextLong(); d sc.nextLong() sc.nextLong sc int a = 0; a 0 for (int i = 1; i <= n; i++) {
      long x = sc.nextLong();
      long y = sc.nextLong();
      if ((d*d) >= (x*x + y*y)) {
        a++;
      }
    } int i = 1; int i = 1; i 1 i <= n i n i++ i++ i {
      long x = sc.nextLong();
      long y = sc.nextLong();
      if ((d*d) >= (x*x + y*y)) {
        a++;
      }
    } {
      long x = sc.nextLong();
      long y = sc.nextLong();
      if ((d*d) >= (x*x + y*y)) {
        a++;
      }
    } long x = sc.nextLong(); x sc.nextLong() sc.nextLong sc long y = sc.nextLong(); y sc.nextLong() sc.nextLong sc if ((d*d) >= (x*x + y*y)) {
        a++;
      } (d*d) >= (x*x + y*y) (d*d) d d (x*x + y*y) x*x x x y*y y y {
        a++;
      } a++ a System.out.println(a) System.out.println System.out System System.out a String[] args args
import java.util.Scanner;
class Main {
  static public void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    long d = sc.nextLong();
    int a = 0;
    for (int i = 1; i <= n; i++) {
      long x = sc.nextLong();
      long y = sc.nextLong();
      if ((d*d) >= (x*x + y*y)) {
        a++;
      }
    }
    System.out.println(a);
  }
}
