In this program, two integer values taken from user and then sum of this values are stored in another variavle and then print it.
#include <iostream>
using namespace std;
int main()
{
int firstNo, secondNo, sumOfTwoNo;
cout << "Enter two integer values: ";
cin >> firstNo >> secondNo;
sumOfTwoNo = firstNo + secondNo;
cout << firstNo << " + " << secondNo << " = " << sumOfTwoNo;
return 0;
}
OutPut
Enter two integer values: 4 5 4 + 5 = 9