How can I make scanf skip a blank line....
I want it to fscanf some numbers
input file:
I'm using a while loop
but the blank space is throwing everything off
how can i tell scanf to skip that empty space and read the number in the next line?
This is my code, although I dont know if it
makes sense cause I'm trying to do other stuff to:
Code:
while( strstr("class siz",temp_name) == NULL) {
fgets(temp_name,30,fin);
if(strlen(temp_name)>9){
temp_name[9] = '\0' ; }
fscanf(fin," %d",&ID);
printf("%d\n",ID);
Thank you