[Haskell] Help-me read file
lemming at henning-thielemann.de
Mon Oct 18 15:31:49 EDT 2010
On Mon, 18 Oct 2010, Gilmara Pompelli wrote:
> I have a file with 100 lists, with 100 ints.
> I have to read the file and apply the map and sort functions on lists.
> II did it to read file:
> learquivo :: FilePath -> IO ([[Int]])
> learquivo s = do
> conteudo <- readFile s
> return (read conteudo)
> But now applying the sort, the error appears:
Where do you apply 'sort' ? You mean
It must be
fmap sort learquivo
More information about the Haskell