Yes, saying it's twice as fast is a bit simplistic. And O(2N) is theoretically the same as O(N), but in practice, if you have a large list of IDs that need to be looked up in a database to do the map and the filter, mapfilter can approach "twice as fast" (how close depends on the map function). This is my general use case, and the reason I wrote a mapfilter function.
It's cool that haskell can do a single iteration by being lazy. I do wish erlang could do lazy iteration and generators.
It's cool that haskell can do a single iteration by being lazy. I do wish erlang could do lazy iteration and generators.