Match List I (Functions) with List II (Uses of functions)
| List I | List II |
|---|---|
| A. fseek() | I. Gives the current position in the file |
| B. ftell() | II. Sets the position to the beginning of the file |
| C. feof() | III. Sets the position to a desired point in the file |
| D. rewind() | IV. Used to test for an end of file condition |
Pick an option to check yourself, or open the answer below.
Show answer & explanation
Correct answer: B. A-III, B-I, C-IV, D-II
Explanation
fseek() sets the position to a desired point (A-III). ftell() gives the current position (B-I). feof() tests for end of file (C-IV). rewind() sets the position to the beginning (D-II).More Programming Languages and Computer Graphics questions
- Which of the following statements is NOT true?
- The light given off by the phosphor during exposure to the electron beam is known as
- Which of the following statements about pointers in C are TRUE? (A) Pointers can be used to access array elements (B) Pointers can store th…
- Consider the function in C code:Cal(a, b) { if (b != 1) { if (a != 1) { printf("*"); Cal(a/2, b); } else { b = b - 1; Cal(10, b); } } } How…
- Which of the following is the correct way to declare a function pointer in C?
- Consider the following C program:#include<stdio.h> int main() { int x[] = {2,4,6,8,10}; int a, b = 0, *y = x + 4; for (a = 0; a < 5; a++) {…