Sven Panne wrote:
> 
> Friedrich Dominicus wrote:
> >[...] How can I combine the output with a line-number can I put that
> > into the filter? Or do I have to found another solution?
> 
> Don't fear! Mr. One-Liner comes to the rescue:    ;-)
> 
>    longerThan fn lenlim = readFile fn >>= lines .| filter (length .| (>lenlim)) .| 
>zip [1..] .| map (\(n,l) -> shows n ") " ++ l) .| unlines .| putStr

Do you want to drive me away from learning Haskell? Who the hell can try
to write such functions? Is readabilty not a concern in Haskell?
> 
> [ This mail is optimised for 1280x1024 in landscape mode... ]

yes and with one completly diffent mindscape ;-)

Regards
Friedrich


Reply via email to