Or fgetc() to read a single character.
Code:
int c;
while((c = fgetc(fp)) != EOF) {
/* do something with character */
}
0408863864 4 F
2307192198 4 D
2107850859 1 D
0702831830 3 B
2808651656 1 C
2810851859 2 C
1610993997 4 F
i need the numbers, the number in the secound row, and the letter in three different varibles
Use fgets() with sscanf(), or fscanf().
Code:
fscanf(fp, "%*i %i %c", &thenumber, &thecharacter);
The %*i tells [f]scanf to read a number, but not to store it in anything.
Is that what you wanted?