Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a program that accepts three decimal numbers interactively from the keyboard, finds the sum, finds the mean average, determines which is the largest number

Write a program that accepts three decimal numbers interactively from the keyboard, finds the sum, finds the mean average, determines which is the largest number of the three numbers. Declare, define and call an integer function, statsSummary(), that accepts all three results (sum, mean average, largest value) as arguments, in the order listed, calculate the sum of the three results and return the integer part of their sum. The function must be called in an output statement.

Here is an example of the expected user interaction of the program:

Program: Stats Summary 
Enter value 1:> 20 Enter value 2:> 40 Enter value 3:> 0  Stats Summary... 120 

This is what I have so far.

#include using namespace std;

//Function Prototype

int main(){ double sum = 0, meanAv = 0, highest = 0, num = 0; int i = 0; cout << "Program: Stats Summary "; highest = -0.0000000000000000000000000001; //Define the for loop and make calculations //Find the mean average //Display results cout << " End of program..."; return 0; }

End of program... 

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Automating Access Databases With Macros

Authors: Fish Davis

1st Edition

1797816349, 978-1797816340

More Books

Students also viewed these Databases questions