Problem

(Program) Write a C++ program that stores the integer value 16 in the variable num1 and...

(Program) Write a C++ program that stores the integer value 16 in the variable num1 and the integer value 18 in the variable num2. (Be sure to declare the variables as integers.) Have your program calculate the total of these numbers and their average. Store the total in an integer variable named total and the average in an integer variable named average. (Use the statement average = total/2.0; to calculate the average.) Use a cout statement to display the total and average.

Step-by-Step Solution

Request Professional Solution

Request Solution!

We need at least 10 more requests to produce the solution.

0 / 10 have requested this problem solution

The more requests, the faster the answer.

Request! (Login Required)


All students who have requested the solution will be notified once they are available.
Add your Solution
Textbook Solutions and Answers Search
Solutions For Problems in Chapter 2.3