c++ arrays and file reading question

I am doing a project and I have to read from a file and input the values into an array. I know how to do this. But now we have to read from a file in put it in multiple arrays. The file that I'm reading looks like this:

4
Assign1 200 95
Assign2 100 80
Project 100 -1
Midterm 100 -1

How would I make it so that the names are put into one array, the 1st numbers in another, and the last numbers in another array?
1
2
3
4
5
6
7
8
9
10
11
12
13
14
int readFile(char fileName[])
{
  int i = 0;
  ifstream input;

  input.open(fileName);

  while (i != input.eof())
    {
      input >> grade[i];
      i++;
    }
  input.close();
}


How do I make it so I store the information in 3 separate arrays instead of just one.
Last edited on
Oh by the way I am using linux to program.
Is this even possible to do?
Topic archived. No new replies allowed.