using less stack
Hal Daume III
hdaume@ISI.EDU
Sat, 23 Mar 2002 16:35:18 -0800 (PST)
Hi,
> You don't have to define cpsfold explicitly recursively since it can be
> expressed in terms of foldr:
Is this generally considered good design? That is, is it generally
preferred to express functions in a nonrecursive style if that can be done
using standard library functions like foldr and map and filter,
etc? Okay, obviousloy everything *can* be done in that manner, so I guess
my question is why should we write something using foldr when, imo, the
explicitely recursive version is easier to parse (as a human).
- Hal