Philippe Sigaud:
We could also have a slightly different version that lazily produces the intermediate results as a range. IIRC, it's called 'scan' in Haskell.
It's already in Bugzilla: http://d.puremagic.com/issues/show_bug.cgi?id=11084 Bye, bearophile