Code:
...
double avg = 0;
while (read_record(fin,t))
{
write_record(out,t);
count ++
avg t = (t.low + t.high)/2.0
// output average
cout << avg t << endl;
...
You might wanna address your variable with
avg since that's what you're calling it..
So it would be:
Code:
...
double avg = 0;
while (read_record(fin,t))
{
write_record(out,t);
count ++ ;
avg = (t.low + t.high)/2.0 ;
// output average
cout << avg << endl;
...
Next time proof read your code more, the
92 infront of the error indicates what line is is pressented on..
The easiest way is to scroll to where the first error tells you it is, see if anything there is missing/wrong, correct that and see if that eliminates the error.