Write a recursive function to solve a specific data-traversal or mathematical problem, and explain its call stack.