Discussion :: Library Functions
-
Point out the error in the following program.
#include
int main() { fprintf("FresherGATE"); printf("%.ef", 2.0); return 0; }
A.
Error: unknown value in printf() statement. |
B.
Error: in fprintf() statement. |
C.
No error and prints "fresherGATE" |
D.
No error and prints "2.0" |
Answer : Option B
Explanation :
Declaration Syntax:
int fprintf (FILE *stream, const char *format [, argument, ...]);
Example:
fprintf(filestream, "%s %d %s", Name, Age, City);
Be The First To Comment