{- imports as before -} main = do args <- getArgs mapM_ output args {- definitions of output, countLinesFile, and hCountLines as before -}