4 ms·
The mechanical transformation described in the article does not change the asymptotic complexity of the program. It just changes it from using an implicit (recu
by ufo 6y ago
The mechanical transformation described in the article does not change the asymptotic complexity of the program. It just changes it from using an implicit (recursion) stack, to using an explicit stack.
The neat thing about that transformation, in my opinion, is that it works even for complicated algorithms. Sometimes you really do need to rewrite something to use an explicit stack, and that can be quite tricky to get right!
- mannykannot 6y agoPoint taken - thanks!