import System.IO
import Data.Char
edastaNr n
= do
putStrLn "Anna rida:"
line <- getLine
if null line
then return ()
else do return length(line)
谁能解释为什么最后一行不正确以及如何修复它?我没有意识到..错误是:
Couldn't match expected type `IO ()' with actual type `[a0] -> Int'