Skip to content

Instantly share code, notes, and snippets.

@dmiyakawa
Created November 29, 2012 13:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dmiyakawa/4169186 to your computer and use it in GitHub Desktop.
Save dmiyakawa/4169186 to your computer and use it in GitHub Desktop.
Compress
import Data.List(group)
import Control.Arrow
solve = concatMap (uncurry (:) . (head &&& show . length)) . group
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment