Re:SICP Goodness – Why you don't need looping constructs
by Const-me on Friday June 29, 2018 @08:21AM
(#17424054)
> which converts properly prepared recursion into an iterative loop
It only works if you are using recursion in place of a simple loop.
Many algorithms traditionally implemented with recursion (e.g. various tree searches) need that stack somewhere.
Technically it’s probably possible to “properly prepare” that, but practically both alternatives (recursion + built-in call stack, or loop + separate stack) are much easier to implement.
That said, I love my for loops, too.