Name: Anonymous 2009-08-16 23:08
Let us discuss the various implementations of theFIBONACCI BUTT SORT.
Let us discuss the various implementations of theFIBONACCI BUTT SORT.
cycle, anyway.tag t str = "[" ++ t ++ "]" ++ str ++ "[/" ++ t ++ "]"
[b,i,o,u] = tag `map` words "b i o u"
dabs = b . i . unwords . zipWith id (cycle [o,u]) . words
fbs = b . i . concat . flip evalState (cycle [o,u]) . mapM f where
f ' ' = return " "
f c = (liftM . concatMap) ($ [c]) (State $ splitAt 1)