C++ Program to find Sum of First and Last Digit of a Number

C++ Program to find Sum of First and Last Digit of a Number 1

Write a C++ Program to Find the Sum of the First and Last Digit of a Number with an example. Here, first, we found the first and last digits in a given number. Next, we performed an arithmetic addition on them. #include<iostream> #include<cmath> using namespace std; int main() { int number, firstDigit, lastDigit, sum, count; … Read more