
22 May
2007
22 May
'07
8:50 a.m.
"Matthew Brecknell"
This seems to work, but presumably only because it's a boxed array, and the construction makes no circular references.
Yes. (-:
However, I'm doubtful that memoisation is really beneficial in this function. I think it only gains a constant-factor speedup, but loses the ability to work in constant space.
I don't know. The memoised version certainly calls the bit with the list comprehension fewer times. I'd have to think about it more. -- Mark