
1 May
2002
1 May
'02
7:06 a.m.
----------------- [moving to haskell-cafe]
I want to read some data from a text file. I accomplished it but I want to read data from file as a Integer list for example text file has [1,2,3,5]
Wait you actually have "[1,2,3,5]" ---------------------
and when I read this data from file I handeled it as string. What can I do to get it as integer list.
Hint: map read ["1","2","3"] ::[Int] ------------------- this would be helpfull if you had "1 2 3 5". It's easier then Hint: read "[1,2,3,5]"::[Int] J.A.