import java.util.*;
public class Main {
  public static void main(String[] args){
    
	Scanner sc = new Scanner(System.in);
	
	int iLine = sc.nextInt();
	long iBase = (long)sc.nextInt();
    iBase = iBase * iBase;

	long iValue1 = 0;
	long iValue2 = 0;
	long iTotal = 0;
	int iLoop = 0;
	int iCount = 0;

	for( iLoop = 0; iLoop < iLine; iLoop++ ){
		iValue1 = (long)sc.nextInt();
		iValue2 = (long)sc.nextInt();

		iValue1 = (long)Math.pow(iValue1,2);
		iValue2 = (long)Math.pow(iValue2,2);
		iTotal = iValue1 + iValue2;
      
		if(iBase >= iTotal){
			iCount++;
		}
	}
    System.out.println(iCount);
  }
} import java.util.*; util.* java public class Main {
  public static void main(String[] args){
    
	Scanner sc = new Scanner(System.in);
	
	int iLine = sc.nextInt();
	long iBase = (long)sc.nextInt();
    iBase = iBase * iBase;

	long iValue1 = 0;
	long iValue2 = 0;
	long iTotal = 0;
	int iLoop = 0;
	int iCount = 0;

	for( iLoop = 0; iLoop < iLine; iLoop++ ){
		iValue1 = (long)sc.nextInt();
		iValue2 = (long)sc.nextInt();

		iValue1 = (long)Math.pow(iValue1,2);
		iValue2 = (long)Math.pow(iValue2,2);
		iTotal = iValue1 + iValue2;
      
		if(iBase >= iTotal){
			iCount++;
		}
	}
    System.out.println(iCount);
  }
} Main public static void main(String[] args){
    
	Scanner sc = new Scanner(System.in);
	
	int iLine = sc.nextInt();
	long iBase = (long)sc.nextInt();
    iBase = iBase * iBase;

	long iValue1 = 0;
	long iValue2 = 0;
	long iTotal = 0;
	int iLoop = 0;
	int iCount = 0;

	for( iLoop = 0; iLoop < iLine; iLoop++ ){
		iValue1 = (long)sc.nextInt();
		iValue2 = (long)sc.nextInt();

		iValue1 = (long)Math.pow(iValue1,2);
		iValue2 = (long)Math.pow(iValue2,2);
		iTotal = iValue1 + iValue2;
      
		if(iBase >= iTotal){
			iCount++;
		}
	}
    System.out.println(iCount);
  } main {
    
	Scanner sc = new Scanner(System.in);
	
	int iLine = sc.nextInt();
	long iBase = (long)sc.nextInt();
    iBase = iBase * iBase;

	long iValue1 = 0;
	long iValue2 = 0;
	long iTotal = 0;
	int iLoop = 0;
	int iCount = 0;

	for( iLoop = 0; iLoop < iLine; iLoop++ ){
		iValue1 = (long)sc.nextInt();
		iValue2 = (long)sc.nextInt();

		iValue1 = (long)Math.pow(iValue1,2);
		iValue2 = (long)Math.pow(iValue2,2);
		iTotal = iValue1 + iValue2;
      
		if(iBase >= iTotal){
			iCount++;
		}
	}
    System.out.println(iCount);
  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int iLine = sc.nextInt(); iLine sc.nextInt() sc.nextInt sc long iBase = (long)sc.nextInt(); iBase (long)sc.nextInt() sc.nextInt sc iBase = iBase * iBase iBase iBase * iBase iBase iBase long iValue1 = 0; iValue1 0 long iValue2 = 0; iValue2 0 long iTotal = 0; iTotal 0 int iLoop = 0; iLoop 0 int iCount = 0; iCount 0 for( iLoop = 0; iLoop < iLine; iLoop++ ){
		iValue1 = (long)sc.nextInt();
		iValue2 = (long)sc.nextInt();

		iValue1 = (long)Math.pow(iValue1,2);
		iValue2 = (long)Math.pow(iValue2,2);
		iTotal = iValue1 + iValue2;
      
		if(iBase >= iTotal){
			iCount++;
		}
	} iLoop = 0; iLoop = 0 iLoop 0 iLoop < iLine iLoop iLine iLoop++ iLoop++ iLoop {
		iValue1 = (long)sc.nextInt();
		iValue2 = (long)sc.nextInt();

		iValue1 = (long)Math.pow(iValue1,2);
		iValue2 = (long)Math.pow(iValue2,2);
		iTotal = iValue1 + iValue2;
      
		if(iBase >= iTotal){
			iCount++;
		}
	} {
		iValue1 = (long)sc.nextInt();
		iValue2 = (long)sc.nextInt();

		iValue1 = (long)Math.pow(iValue1,2);
		iValue2 = (long)Math.pow(iValue2,2);
		iTotal = iValue1 + iValue2;
      
		if(iBase >= iTotal){
			iCount++;
		}
	} iValue1 = (long)sc.nextInt() iValue1 (long)sc.nextInt() sc.nextInt sc iValue2 = (long)sc.nextInt() iValue2 (long)sc.nextInt() sc.nextInt sc iValue1 = (long)Math.pow(iValue1,2) iValue1 (long)Math.pow(iValue1,2) Math.pow Math iValue1 2 iValue2 = (long)Math.pow(iValue2,2) iValue2 (long)Math.pow(iValue2,2) Math.pow Math iValue2 2 iTotal = iValue1 + iValue2 iTotal iValue1 + iValue2 iValue1 iValue2 if(iBase >= iTotal){
			iCount++;
		} iBase >= iTotal iBase iTotal {
			iCount++;
		} iCount++ iCount System.out.println(iCount) System.out.println System.out System System.out iCount String[] args args public class Main {
  public static void main(String[] args){
    
	Scanner sc = new Scanner(System.in);
	
	int iLine = sc.nextInt();
	long iBase = (long)sc.nextInt();
    iBase = iBase * iBase;

	long iValue1 = 0;
	long iValue2 = 0;
	long iTotal = 0;
	int iLoop = 0;
	int iCount = 0;

	for( iLoop = 0; iLoop < iLine; iLoop++ ){
		iValue1 = (long)sc.nextInt();
		iValue2 = (long)sc.nextInt();

		iValue1 = (long)Math.pow(iValue1,2);
		iValue2 = (long)Math.pow(iValue2,2);
		iTotal = iValue1 + iValue2;
      
		if(iBase >= iTotal){
			iCount++;
		}
	}
    System.out.println(iCount);
  }
} public class Main {
  public static void main(String[] args){
    
	Scanner sc = new Scanner(System.in);
	
	int iLine = sc.nextInt();
	long iBase = (long)sc.nextInt();
    iBase = iBase * iBase;

	long iValue1 = 0;
	long iValue2 = 0;
	long iTotal = 0;
	int iLoop = 0;
	int iCount = 0;

	for( iLoop = 0; iLoop < iLine; iLoop++ ){
		iValue1 = (long)sc.nextInt();
		iValue2 = (long)sc.nextInt();

		iValue1 = (long)Math.pow(iValue1,2);
		iValue2 = (long)Math.pow(iValue2,2);
		iTotal = iValue1 + iValue2;
      
		if(iBase >= iTotal){
			iCount++;
		}
	}
    System.out.println(iCount);
  }
} Main
import java.util.*;
public class Main {
  public static void main(String[] args){
    
	Scanner sc = new Scanner(System.in);
	
	int iLine = sc.nextInt();
	long iBase = (long)sc.nextInt();
    iBase = iBase * iBase;

	long iValue1 = 0;
	long iValue2 = 0;
	long iTotal = 0;
	int iLoop = 0;
	int iCount = 0;

	for( iLoop = 0; iLoop < iLine; iLoop++ ){
		iValue1 = (long)sc.nextInt();
		iValue2 = (long)sc.nextInt();

		iValue1 = (long)Math.pow(iValue1,2);
		iValue2 = (long)Math.pow(iValue2,2);
		iTotal = iValue1 + iValue2;
      
		if(iBase >= iTotal){
			iCount++;
		}
	}
    System.out.println(iCount);
  }
}