import Control.Monad

readInt = readLn :: IO Int
readInts = map read . words <$> getLine :: IO [Int]
readNInts = flip replicateM readInts

main :: IO ()
main = do
    [n, h, w] <- readInts
    ab <- readNInts n
    print . length $ filter (\[x, y] -> h <= x && w <= y) ab