I've been following a Learn Haskell in 10 Minutes tutorial. Everything was going well until I reached this line:
do { n <- readLn ; print (n^2) }
It won't execute in ghci, and in Leksah I get the following error.
Parse error: naked expression at top level
I've tried updating cabal and installing foo, but the problem continues.
Your help would be greatly appreciated.
I'm using Ubuntu 11.10.
main = do { ... }
. – hammar