91.
What will be the output of the following C code?
#include <stdio.h>
int main()
{
    srand(time(NULL));
    printf("%d\n", rand());
    return 0;
}

92.
What will be the output of the following C code?
#include <stdio.h>
#include <string.h>
int main()
{
    char line[3];
    FILE *fp;
    fp = fopen("newfile.txt", "r");
    while (fgets(line, 3, fp))
    fputs(line, stdout);
    return 0;
}

94.
What will be the output of the following C code?
#include <stdio.h>
int main(int argc, char **argv)
{
    char *s = "myworld";
    int i = 3;
    printf("%10.*s", i, s);
}

Read More Section(File Input Output)

Each Section contains maximum 100 MCQs question on File Input Output. To get more questions visit other sections.