3 ms·
Oh yes, and Forth has an elegant solution to Paul Graham's "accumulator generator" problem (though Forth isn't dynamically typed, so it only works for integers)
by benhoyt 19y ago
Oh yes, and Forth has an elegant solution to Paul Graham's "accumulator generator" problem (though Forth isn't dynamically typed, so it only works for integers):
: accgen create , does tuck +! @ ;
From comp.lang.forth:
http://groups.google.com/group/comp.lang.forth/msg/f06370fed978abff?dmode=source http://groups.google.com/group/comp.lang.forth/msg/f06370fed978abff?dmode=source