0
I am reading a file with the following lines:
ADD 50
ADD 30
ADD 10
ADD 12
And I wanted to read only the integer values for a vector.
I’m using this code:
while(EOF)
{
        aux=(char*)malloc(1000*sizeof(char));
        if(aux==NULL){
            printf("ERROR, vector\n");
            exit(1);
        }
        aux[i]=fgets(aux,tam);
        i++;
}
However this is not what I want because so I keep the ADD too.