@ -1 +1,12 @@
#inlcude "average_median.h"
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
double average(const double *data, int n) {
double sum = 0.0;
for (int i = 0; i < n; ++i) {
sum += data[i];
}
return sum / n;