I want to get my input to be a list of lists. Each row of text has to be a list of strings and the full text will be the list of lists. How could I do this? I have this as the main:
main :: IO ()
main = interact (lines >>> foo >>> unlines)
So if this is the input:
These are random
Words of text
example example example
The result should be this:
[[These, are, random], [Words, of, text],[example, example, example]]
[String]list into a[[String]]list. Based on what condition? Do you want the "words" of that line?