[Haskell-cafe] Re: Why is there no splitBy in the list module?
Yitzchak Gale
gale at sefer.org
Tue Jul 11 18:41:23 EDT 2006
I personally use
split :: Eq a => [a] -> [a] -> [[a]]
all the time, much more often than
splitBy :: (a -> Bool) -> [a] -> [[a]]
But I don't call it "split". By analogy with
concatMap, the Haskell analogue of Perl/Python
"join" is concatIntersperse. Then, by analogy
with lines/unlines, the Haskell analogue of
"split" is... unconcatIntersperse.
Hmm...
More information about the Haskell-Cafe
mailing list