Broke apart recursion into steps.