

MCQOPTIONS
This section includes 564 Mcqs, each offering curated multiple-choice questions to sharpen your Engineering knowledge and support exam preparation. Choose a topic below to get started.
451. |
Would the following typedef work? |
A. | Yes |
B. | No |
Answer» C. | |
452. |
Will the program compile successfully?
|
A. | Yes |
B. | No |
Answer» B. No | |
453. |
Will the program compile successfully?
|
A. | Yes |
B. | No |
Answer» C. | |
454. |
What will be the output of the program ?
|
A. | 30 |
B. | 27 |
C. | 9 |
D. | 3 |
Answer» B. 27 | |
455. |
In the following program add a statement in the function fact() such that the factorial gets stored in j.
|
A. | j=s; |
B. | *j=s; |
C. | *j=&s; |
D. | &j=s; |
Answer» C. *j=&s; | |
456. |
Will the program compile successfully?
|
A. | Yes |
B. | No |
Answer» B. No | |
457. |
What will be the output of the program ?
|
A. | ink |
B. | ack |
C. | ite |
D. | let |
Answer» B. ack | |
458. |
We should not read after a write to a file without an intervening call to fflush(), fseek() or rewind() |
A. | True |
B. | False |
Answer» B. False | |
459. |
If the different command line arguments are supplied at different times would the output of the following program change?
|
A. | Yes |
B. | No |
Answer» C. | |
460. |
Offset used in fseek() function call can be a negative number. |
A. | True |
B. | False |
Answer» B. False | |
461. |
In a call to printf() function the format specifier %b can be used to print binary equivalent of an integer. |
A. | True |
B. | False |
Answer» C. | |
462. |
What will be the output of the program ?
|
A. | Mello |
B. | Hello |
C. | HMello |
D. | MHello |
Answer» B. Hello | |
463. |
What will be the output of the program If the integer is 4bytes long?
|
A. | 8, 8, 8 |
B. | 4000, 4002, 4004 |
C. | 4000, 4004, 4008 |
D. | 4000, 4008, 4016 |
Answer» B. 4000, 4002, 4004 | |
464. |
In the following program add a statement in the function fun() such that address of a gets stored in j?
|
A. | **k=a; |
B. | k=&a; |
C. | *k=&a |
D. | &k=*a |
Answer» D. &k=*a | |
465. |
What will be the output of the program ?
|
A. | Error |
B. | d |
C. | e |
D. | abcdefgh |
Answer» D. abcdefgh | |
466. |
What will be the output of the following program in 16 bit platform assuming that 1022 is memory address of the string "Hello1" (in Turbo C under DOS) ?
|
A. | 1022 Hello2 |
B. | Hello1 1022 |
C. | Hello1 Hello2 |
D. | 1022 1022 |
E. | Error |
Answer» B. Hello1 1022 | |
467. |
What will be the output of the program in Turbo C?
|
A. | India BIX |
B. | BIX |
C. | India |
D. | Error |
Answer» E. | |
468. |
What will be the output of the program ?
|
A. | India BIX |
B. | BIX India |
C. | India India |
D. | BIX BIX |
Answer» C. India India | |
469. |
What will be the output of the program ?
|
A. | Equal |
B. | Unequal |
C. | Error |
D. | None of above |
Answer» C. Error | |
470. |
What will be the output of the program ?
|
A. | The string is not empty |
B. | The string is empty |
C. | No output |
D. | 0 |
Answer» C. No output | |
471. |
What will be the output of the program?
|
A. | 3 |
B. | 4 |
C. | 0 |
D. | No output |
Answer» B. 4 | |
472. |
What will be the output of the program?
|
A. | junk |
B. | MESS |
C. | Error |
D. | Nothing will print |
Answer» C. Error | |
473. |
What will be the output of the program?
|
A. | 5 |
B. | 9 |
C. | 10 |
D. | 3+7 |
Answer» D. 3+7 | |
474. |
What will be the output of the program ?
|
A. | Unpredictable integer value |
B. | 0 |
C. | -1 |
D. | Error |
Answer» B. 0 | |
475. |
What will be the output of the program?
|
A. | 2, 3, 4, |
B. | 2, 2, 2, |
C. | 3, 3, 3, |
D. | 4, 4, 4, |
Answer» B. 2, 2, 2, | |
476. |
What will be the output of the program ?
|
A. | Garbage value |
B. | Error |
C. | No output |
D. | diaBIX |
Answer» B. Error | |
477. |
What will be the output of the program ?
|
A. | Kagpur, Kanpur |
B. | Nagpur, Kanpur |
C. | Kagpur, anpur |
D. | Error |
Answer» E. | |
478. |
Can a structure can point to itself? |
A. | Yes |
B. | No |
Answer» B. No | |
479. |
If a char is 1 byte wide, an integer is 2 bytes wide and a long integer is 4 bytes wide then will the following structure always occupy 7 bytes?
|
A. | Yes |
B. | No |
Answer» C. | |
480. |
What will be the output of the program given below in 16-bit platform ?
|
A. | 1 |
B. | 2 |
C. | 4 |
D. | 10 |
Answer» C. 4 | |
481. |
It is not possible to create an array of pointer to structures. |
A. | True |
B. | False |
Answer» C. | |
482. |
What will be the output of the program ?
|
A. | -1, 0, 1, 2, 3, 4 |
B. | Error |
C. | 0, 1, 6, 3, 4, 5 |
D. | 0, 0, 6, 7, 8, 9 |
Answer» C. 0, 1, 6, 3, 4, 5 | |
483. |
What will be the output of the program ?
|
A. | 12, 12, 12 |
B. | 112, 1, 12 |
C. | 32, 1, 12 |
D. | -64, 1, 12 |
Answer» B. 112, 1, 12 | |
484. |
What will be the output of the program in 16-bit platform (under DOS)?
|
A. | 2, 2 |
B. | 8, 8 |
C. | 5, 5 |
D. | 4, 4 |
Answer» B. 8, 8 | |
485. |
What will be the output of the program (myprog.c) given below if it is executed from the command line?
If the first value printed by the above program is 65517, what will be the rest of output? |
A. | 65525 65531 |
B. | 65519 65521 |
C. | 65517 65517 |
D. | 65521 65525 |
Answer» C. 65517 65517 | |
486. |
What will be the output of the program ?
|
A. | 1 |
B. | -1 |
C. | 0 |
D. | Error |
Answer» C. 0 | |
487. |
Point out the compile time error in the program given below.
|
A. | Error: invalid assignment for x |
B. | Error: suspicious pointer conversion |
C. | No error |
D. | None of above |
Answer» D. None of above | |
488. |
Point out the error in the program
|
A. | Error: Declaration syntax |
B. | Error: Expression syntax |
C. | Error: LValue required |
D. | Error: Rvalue required |
Answer» D. Error: Rvalue required | |
489. |
stderr, stdin, stdout are FILE pointers |
A. | Yes |
B. | No |
Answer» B. No | |
490. |
A file written in text mode can be read back in binary mode. |
A. | Yes |
B. | No |
Answer» C. | |
491. |
Is there easy way to print enumeration values symbolically? |
A. | Yes |
B. | No |
Answer» C. | |
492. |
By default structure variable will be of auto storage class |
A. | Yes |
B. | No |
Answer» B. No | |
493. |
Is it necessary that the size of all elements in a union should be same? |
A. | Yes |
B. | No |
Answer» C. | |
494. |
Will the following declaration work?
|
A. | Yes |
B. | No |
Answer» B. No | |
495. |
Are the expression *ptr++ and ++*ptr are same? |
A. | True |
B. | False |
Answer» C. | |
496. |
Will the program compile?
|
A. | True |
B. | False |
Answer» B. False | |
497. |
Are the three declarations char **apple, char *apple[], and char apple[][] same? |
A. | True |
B. | False |
Answer» C. | |
498. |
Will the following program work?
|
A. | Yes |
B. | No |
Answer» B. No | |
499. |
The following program reports an error on compilation.
|
A. | True |
B. | False |
Answer» C. | |
500. |
Is there any difference between the following two statements? |
A. | Yes |
B. | No |
Answer» C. | |