Hello I'm having an issue with my code when trying to manipulate my output. My program consists of main.cpp, StudentType.cpp, and StudentType.h. My problem is occuring in StudentType.cpp in this section:
Code:
void StudentType::printData(std::ostream& out){
out << setw(15) << name;
for (int i=0; i<NUM_GRADES; ++i){
out << setw(3) << grades[i];
}
out << setw(5) << fixed << setprecision(2) << average << std::endl;
}
I thought including iomanip would fix it but it did not. I tried to include it in main and in StudentType.cpp and still get the error "setw is not declared in this scope". Any help would be very much appreciated.