Why is this function not working? Sigh...I am getting a warning....warning C4700: local variable 'lowest' used without having been initialized...but I did initialize it at the start...
Code:
double average(int array[], int numts)
{
int lowest, total = 0, total2 = 0;
double avg;
for (int count = 0; count < numts; count++)
total += array[count];
total2 = total - lowest;
avg = total2 / numts;
return avg;
}