
14 Dec
2010
14 Dec
'10
12:31 p.m.
On 14 December 2010 15:38, Lennart Augustsson
Yes, chop can be easily written in terms of unfoldr. But the chop function fits better with other existing list functions, like I tried to illustrate with my examples.
I'd expect the primitive definition of chop to be more efficient as well - as there is no intermediate Maybe type. chop - seems a nice function. I'd like to see it in Data.List. Best wishes Stephen