Comment by wagwang
1 day ago
Normal recursion is just a loop and a stack, turns out, if you can optimize recursion without a stack, it just becomes a loop.
1 day ago
Normal recursion is just a loop and a stack, turns out, if you can optimize recursion without a stack, it just becomes a loop.
It is still the same stack, but it reuses the existing stack frame.