[Haskell-cafe] ANNOUNCE: The Monad.Reader - Issue 6

Spencer Janssen sjanssen at cse.unl.edu
Thu Feb 1 16:07:01 EST 2007


Yet another higher order solution:

dropWhile' p0 xs = foldr f (const []) xs $ p0
   where
     f y ys p | p y       = ys p
              | otherwise = y : ys (const False)


Spencer Janssen


More information about the Haskell-Cafe mailing list