So I'm trying to take some information that a user inputs and to then write it into a .txt file. The user would input a student ID followed by 4 quiz grades. I need to use nested loops for the input, a while loop for the outer and a for loop for the inner.
The data in the .txt should would look like:
studentID quiz1 quiz2 quiz3 quiz4
studentID quiz1 quiz2 quiz3 quiz4
etc.
My problem is I'm not sure how to structure the code. I have very few examples I'm working with to understand what I'm working with. Any help is appreciated.
I need to use nested loops for the input, a while loop for the outer and a for loop for the inner.
Just go piece by piece.
Brick by brick.
There's a ton of info out there on reading data from a txt file.
Such as this very similar question: http://www.cplusplus.com/forum/beginner/71965/
I still don't have a clue on how to structure this. Below is what I've come up with...it doesn't work real well. My problem is I don't know how to write this nested loop to gather the student ID then 4 quiz grades and then to ask enter 1 for more students or 0 for none...