Discussion :: Input / Output
-
Point out the error in the program?
#includeint main() { FILE *fp; fp=fopen("trial", "r"); fseek(fp, "20", SEEK_SET); fclose(fp); return 0; }
|
A.
Error: unrecognised Keyword SEEK_SET |
|
B.
Error: fseek() long offset value |
|
C.
No error |
|
D.
None of above |
Answer : Option B
Explanation :
Instead of "20" use 20L since fseek() need a long offset value.
Be The First To Comment

Whatsapp
Facebook