Program to find the sum of digits of a number using recursion in C++. Solution #include <iostream> using namespace std; int sumdigit(int n) { if (n == 0) return 0;…
C++ ProgramsProgramsRecursive Function
Program to find the sum of digits of a number using recursion in C++. Solution #include <iostream> using namespace std; int sumdigit(int n) { if (n == 0) return 0;…