4 ms·
insert is fold, just underspecified (what happens on 1- or 0-element lists? in what direction does the operator associate?). The only difference in comprehensib
by rntz 16y ago
insert is fold, just underspecified (what happens on 1- or 0-element lists? in what direction does the operator associate?). The only difference in comprehensibility is in the language being used to describe the operation - which is certainly a good thing to take note of if you're trying to teach FP, but it's not as if the operation itself is somehow less-comprehensible.