Question
****C++ CODE**** This program will first print a description of what the program does. Actually, ALL programs SHOULD do this as their first step, whether
****C++ CODE****
This program will first print a description of what the program does. Actually, ALL programs SHOULD do this as their first step, whether instructions to do so appear in the requirements or not! Next, the program should generate three integers between 1 and 100, inclusive. You will want to verify that you are in fact generating values in this exact range. Next, calculate the average of these three numbers, taking care to calculate and store the average with accuracy to two decimal places. Finally, display the three randomly generated integers on one line, preceded by a label, and on the following line a label and the value of the average, displayed with exactly two accurate decimal places. Your program should work properly for any three random values in the required range, but here are two examples of what your program could display. Make sure your programs output is very similar, although your numeric values will be different most of the time.
Example 1:
This program will pick three random numbers between 1 and 100, inclusive, calculate their average, and then display the numbers and their average. . . Numbers: 36, 82, 16 Average: 44.67
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started