Question: Please use simple C language and no strings please. Also please use printf and scanf instead of cout and cin. 4. Modify the program written
4. Modify the program written in question 1 to use a single function to compute all three averages. In more detail, write the program, permeabilitylfunction.c, whose main carries out the following steps: open the two files samples.txt and samplesout2.txt read the values from sanples.txt into the array x and determine the value of n (number of values in the file). call the function averages which computes the arithmetic, geometric and harmonic av erages. write the three averages to the file samplesout2.txt / File: permeabilitylfunction.c A set of permeabilities is read from a file into an array A single function is called to compute the arithmetic, geometric and harmonic average Queation 4 DalID: Courae: ENGH 1081 Aaaignnent:5 Progranser Date: M/ #include
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
