First, you're going to use strtok() to "tokenize" your line of input. This means it will split it into chunks. You'll make it split at the spaces of course.
As long as your data follows the pattern you have above, you can skip the first two, then use atoi() to convert from ASCII to integers.
Store these integers in an array, and you can do what you like with them.
Some rough pseudocode for getting the values you want could look like this:
char *ptr;
for each line
{
ptr=strtok(lineOne," "); // do the initial strtok with a pointer to your string.
//At this point ptr points to the first name
for(number of things in the line using an index variable)
{
ptr=strtok(NULL," "); // at this point ptr points to the last name
if(index==0)
{
continue; //causes the for loop to skip the rest and go to the next iteration
}
else
{
ptr=strtok(NULL," "); // at this point ptr points to one of the integer values,
//index=1 being the first one.... (careful not to get off by one here)
int value=atoi(ptr)
/// stuff the value into your array... etc...
storageArray[index-1]=value; /// or something like this
.....
}
}
}