import           Control.Monad

main :: IO ()
main = do
    [n, d] <- map read . words <$> getLine
    xs <- map (map read . words) <$> replicateM n getLine
    let ans = length [ x| x <- xs, sqrt ((x!!0)**2 + (x!!1)**2) <= fromIntegral d ]
    print ans
