Problem

Power Plant Data. The data file power1.dat contains a power plant output in mega watts ove...

Power Plant Data. The data file power1.dat contains a power plant output in mega watts over a period of 8 weeks. Each row of data contains 7 integers that represent 1 week’s data. In developing the following programs, use symbolic constants NROWS and NCOLS to represent the number of rows and the number of columns in the array used to store the data. (Generate a file to test these problems.)

Write a function to compute the average of a specified column of a two-dimensional array that has NROWS rows and NCOLS columns. The parameters should be the integer array and the desired column. Assume that the corresponding function prototype is

double col_ave(int x[NROWS,NCOLS],int col);

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