Question: Please explain what is the problem with the code, and write the correct program, make sure it's correct (I'll rate your answer) 5) The following
5) The following function supposedly computes the sum and average of the numbers in the array a, which bas length n. Variables avg and sum point to variables that the function should modify. Unfortunately, the function contains several errors; find and correct them. void avg sum (double a0, int n, double 'avg, double *sum) int i sum 0.0; for (i 0; i
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
