Concept of recursive function to take user input of two numbers and performs an addition of those two numbers
/* * p4_pshr_Adder.cpp * * Created on: Nov 23, 2010 * Program Description: * This program uses the concept of recursive function to take user input of two numbers and * performs an addition of those two numbers. */ #include <iostream> #include <cctype> #include <iomanip> using namespace std; class Add { private: public: unsigned int Adder(unsigned int, unsigned int); }; unsigned int Add::Adder(unsigned int num1,unsigned int num2) { // This recursive function very smartly deals with the 3 possible cases of the input number // entered by the user being both equal to zero, one number being equal to zero and other number // being equal to zero. if (num1 != 0 && num2 != 0) { // If both number entered by user becomes zero, this recursive function comes to and end // and moves to the next line. But, if both the numbers are non-zero, then, it adds "2" // the times either one...