1 / 12
What is the output of the following 'C' program ?
Answer: Option A
The condition is checked against EOF, it should be checked against NULL.
Tags: No Tags on this question yet!
2 / 12
If the content of a file (input) is abc def. What will be the value of input and ch?.
fp = fopen("input","rb");
fscanf(fp, "%s" ,&input);
fscanf(fp, "%c" ,&ch);
printf("%s %c", input, ch);
Answer: Option C
It will not scan anything after a space is encountered.
3 / 12
If a file contains the line "I am an Indian\r\n" then on reading this line into the array str using fgets().
what would str contain?
Answer: Option B
Here is no explanation for this answer
4 / 12
In the following 'C' code, fp points to
fp = fopen ("trial", "r");
5 / 12
In the following statement, the variable fpt is
fprintf(fpt, "%n", i);
6 / 12
The function fopen ("filename","r") returns
7 / 12
The expression ((fpt = fopen ("Samples", "w")) == NULL) would be true if
This is because here 'w' means it truncate file to zero length or create text file for writing. The stream is positioned at the beginning of the file. But, it is null hence, the file "sample" could not be created for writing.
8 / 12
In mulit-list organization
9 / 12
Which of the following is/are advantages of cellular partitioned structure:
10 / 12
x = fopen (b, c) what is b?