Call stack is hard to maintain in my brain. What should I?
Do not consider call stacks for recursive algorithms. Ever. Forbidden!
Learn to understand recursive algorithms like any other algorithm that calls other procedures: Assume the calls do their work correctly, and concentrate on making sure the right calls are made, and the results are combined correctly.
Separately, try to find some criterion by which the recursive calls are to &quot;smaller&quot; instances of the problem (assuming instance sizes are e.g. positive integers), and that all &quot;small enough&quot; instances are solved correctly by &quot;base cases&quot; (without recursive calls).
Often the recursive algorithm is modelled on some recursive definition of the structure at hand, then the mapping is simple to prove correct. For an entertaining example of a recursive program that doesn't clearly fall into this category, read and understand Rob Pike's regexp matcher (exegesis by Brian Kernighan)