Added an alternate C++ recursion method that is slightly faster.

Signed-off-by: retep998 <retep998@verizon.net>