shortLinesOnly :: IO ()
shortLinesOnly = interact result
where
shortLength = 11
onlyShorts = (<= shortLength) . length
shortLines = filter onlyShorts . lines
result = unlines . shortLines
interact result = getContents >>= putStr . result
在上面的代码中,我如何以无点样式编写交互函数。