If necessary, create a new project named TryThis17 Project and save it in the Cpp8Chap11 folder. Enter
Question:
If necessary, create a new project named TryThis17 Project and save it in the Cpp8\Chap11 folder. Enter the C++ instructions shown earlier in Figure 11-19 into a source file named TryThis17.cpp. Change the filename in the first comment to TryThis17.cpp. Insert a blank line below the first comment, and then enter the following comment: //Also displays the average number of calories consumed.
Save and then run the program. Test the program using the following calorie amounts: 1650, 1700, 1500, 2000, and 1545. Now, modify the program to include the function call and getAverage function shown in Figure 11-21. Display the average as a whole number. Save and then run the program. Test the program using the same data shown here.
Fantastic news! We've Found the answer you've been seeking!
Step by Step Answer:
Related Book For
Question Posted: