http://www.perlmonks.org?node_id=847962


in reply to Re: Golf: Length of longest line in a file
in thread Golf: Length of longest line in a file

well, you could have used liftM and merge map length in the fold function

liftM (foldl (\x y -> max x $ length y) 0 . lines) $hGetContents stdin

oh.. wait.. what is this?