File Input Output - Study Mode
[#271] What will be the output of the following C code? #include <stdio.h>
#include <stdlib.h>
int main()
{
FILE *fp = stdout
int n
fprintf(fp, "%d", 45)
}
Correct Answer
(B) 45
[#272] Which of the following is the correct declaration for ungetc?
Correct Answer
(C) int ungetc(int c, FILE *fp)
[#273] What will be the output of the following C code? #include <stdio.h>
#include <math.h>
int main()
{
int i = 10
printf("%f
", log10(i))
return 0
}
Correct Answer
(B) 1.000000
[#274] What is meant by 'a' in the following C operation? fp = fopen("Random.txt", "a")
Correct Answer
(B) Append
[#275] The syntax of the scanf() is scanf("control string ", arg1,arg2,arg3,....,argn)
the prototype of control string is
Correct Answer
(A) [=%[width][modifiers]type=]