start here
Code:
#include <stdio.h>
int main()
{
// your code goes here
return 0;
}
you will need a character array of about 255 characers (to hold the longest possible filename) then call fgets() to get the file name from the keyboard. After that, call fopen() to open the file, fgets() to read each line, and finally fclose() to close the file.
Code:
display prompt to enter filename
get filename from keyboard (use fgets() function)
open the file
start of loop
call fgets() to read one line from the file
if fgets() returns NULL then exit the loop
call some other function with line as parameter
end of loop
close file