0
recursion
what is recursion in c++ and also the advantage and disadvantage ?
1 Answer
+ 2
Recursion happends when a function calls itself.
The advantages is that you can write short algorithms for some tasks (like factorials).
A disadvantage in c++ is that you have a recursion limit (because of the Stack).