On 12-07-23 10:52 PM, Qi Qi wrote:
Foldl has the space leak effect, and that's why foldl' has been
recommended.
foldr (+) and foldl (+) for Int have the same asymptotic costs, both
time and space. See my http://www.vex.net/~trebla/haskell/lazy.xhtml
Therefore, I do not understand why they are labeled opposite space-leakness.
Perhaps it is an intuition leak, not a space leak. That is, one of them
fulfills your intuition, the other fails your intuition.
_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe