News for hackers. Stuff that matters.
Re:Hey, C Is a Functional Language Too by eru on Friday November 02, 2012 @02:37PM (#4734093)
With foldl', of course. If you don't have tail recursion elimination, foldl' would have to be provided as a built-in.

Summing up numbers is inherently strict, so you'd want tail call elimination for that. But functional mainstains, like say, map or filter are usually not implemented with tail recursion in Haskell, because that would be too strict and would break on infinite lists.

There are no comments on this comment yet.