Question: Write a program in C++ that accepts the values of two variables num1 and num2 from the user and Add them and store the result
Write a program in C++ that accepts the values of two variables num1 and num2 from the user and
- Add them and store the result in a third variable sum.
- Subtract them and store the result in a fourth variable difference.
- Multiply them and store the result in a fifth variable product.
Display the output of this program in the following format:
Sum of ____________ and ____________ is _______________.
Difference of ____________ and ____________ is ____________.
Product of ____________ and ____________ is ______________.
These dashes will have the values of num1, num2, sum, difference and product respectively.Step by Step Solution
3.42 Rating (146 Votes )
There are 3 Steps involved in it
Solu... View full answer
Get step-by-step solutions from verified subject matter experts
