|
|
When a (recursive) function F(n) calls the (recursive) function F(n-1):
|
If 2 methods do not share their state (= information in variables), then they are actually 2 different activations that operate independently from each other.
Analogy:
|
|
|
|
We have already studied how to pass parameters using the stack and how to allocate local variables on the stack
I will illustrate the how to guide by writing a few recursive methods in assembler code next.