
10 Sep
2009
10 Sep
'09
7:58 a.m.
I know myFoldl implements foldl using foldr. However i really donot know how it can do it ?
You will probably like Graham Hutton A Tutorial on the Universality and Expressiveness of Fold JFP, 1999. http://www.cs.nott.ac.uk/~gmh/fold.pdf Section 5.1 (actually, suml in Section 5) of the paper explains how the expression of foldl in terms of foldr can be _calculated_. The result is correct by construction.