How would you parse the contents of a multi-line text file formatted using a fixed pattern without pre-loading its contents into a variable and then processing them in memory?
Using fscanf()
Correct:
Using fscanf()
The fscanf function can be used to parse the contents of a file according to a fixed predefined
pattern; therefore, the correct answer is C. The sscanf function only operates on strings.