File Input Output MCQs

296 questionsC-ProgramPage 18 of 33

Practice free File Input Output multiple-choice questions with instant answer feedback and step-by-step solutions. Click an option to check yourself, reveal the full explanation, and work through all 296 questions — no login required.

Question 154hard
What will be the output of the following C code?
#include <stdio.h>
#include <ctype.h>
int main()
{
    char i = 9;
    if (isdigit(i))
        printf("digit\n");
    else
        printf("not digit\n");
        return 0;
}
Question 155easy
Which of the following causes an error?
Question 156medium
Which header file includes a function for variable number of arguments?
Advertisement
Question 157easy
fputs() adds newline character.
Question 158easy
For binary files, a . . . . . . . . must be appended to the mode string.
Question 159easy
The type va_list in an argument list is used . . . . . . . .
Advertisement
Question 160medium
The standard header . . . . . . . . is used for variable list arguments (...) in C.
Question 161easy
Which one of the following is correct syntax for opening a file.
Question 162hard
What will be the output of the following C code (when 4 and 5 are entered)?
#include <stdio.h>
void main()
{
    int m, n;
    printf("enter a number");
    scanf("%d", &n);
    scanf("%d", &m);
    printf("%d\t%d\n", n, m);
}