can anyone tell me what am doing wrong i get 1 error average = find_average(input_numbers) only take 1 argument.And it have to find the highest and lowest number. after I remove average = find_average(input_numbers) I get more errors on highest and lowest is uninitialized local variable & find_average & average is unreferenced.
{ int count = 0;
do
{
count++;
while (input >> value)
{
sum += value;
count++;
}
return sum/count;
}
void output(const char name[], int highest, int lowest, ostream& os) // Print results
{ os << "\n\nInput File Name : " << name << endl;
os << "Largest Number is : " << setw(8) << highest << endl;
os << "Smallest Number is: " << setw(8) << lowest << endl;
os << "The Average is : " << setw(8) << find_average << endl; }[/code]
you are missing a return bracket, as best as I can tell, there is something hinky with the return bracket on your initial/outermost do/while loop. Line 60 of my test editor shows the following bracket as the return to the to this do/while loop.
can you copy and paste your latest revision in code tag (the <> symbol to the right that appears when you are inputting a response) so I can see the error myself and the line on which it occurs?, thanks