Recursion Implementing While Loop In Module That Will Iterate Correctly Mathematica Stack

Recursion Implementing While Loop In Module That Will Iterate Correctly Mathematica Stack