
23 Sep
2007
23 Sep
'07
1:11 a.m.
On 9/23/07, Thomas Hartman
-- this is the usual implementation right? myreverse xs = foldl f [] xs where f accum el = el : accum
This is often written reverse = foldl (flip (:)) [] which I quite like, because you can contrast it with foldr (:) [] which of course is just a type-restricted version of id. Stuart