Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on C-style vs. Python-style syntax: which one would you prefer for your next programming language?. Parent comment
For example, I recently needed to do some Run-Length Encoding:
import Control.Arrow import Data.List encodeRLE :: (Eq a) => [a] -> [(Int, a)] encodeRLE = map (length &&& head) . group decodeRLE :: [(Int, a)] -> [a] decodeRLE = concatMap (uncurry replicate)
There are no comments on this comment yet.
For example, I recently needed to do some Run-Length Encoding: