Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Input file name engine.dat Objectives Practice using two dimensional vectors to implement algorithms to solve a problem. Understand the mathematics of basics statistics: min, max,
Input file name engine.dat Objectives Practice using two dimensional vectors to implement algorithms to solve a problem. Understand the mathematics of basics statistics: min, max, and average. Be able to write a C++ program to compute basic statistics. 1. 2. 3. Instructions 1. Start with program Source8 s.cpp 2. Read the data file engine.dat. Do NOT ask the user to enter the filename. The first line contains the number of coordinates in the file Print out the raw data in rows and columns. Format is up to you. Be sure you are descriptive. 4. Create a new function called rowAvg to average the values of the rows. Call the function from 3. the main part of program. Hint: see how input2D computes the number of columns 5. Then create functions to compute the min and max for each row and each column. 6. Make sure you add a system("pause") before the return and before any exits. 7. Add comments and white space as needed. Functions Below are the function prototypes of the functions you must create. You are free to use your own variable names H arr. int rowNum); double rowAvg(vectors v double columnMin(vectore vectorsdouble am, int colNum): double row Min(vectors vector doubles arr, int row Num) doubl column Max(vectors vector doubleH P arr, int colNum): double rowMax(vectors vector doubler P arr, int rowNum): Output to the Console Output is up to you. Be sure to print out all fields and make sure they are labeled correctly
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