What will be the following code's output if choice = 'R'?switch(choice){ case 'R' : printf("RED"); case 'W' : printf("WHITE"); case 'B' : printf("BLUE"); default : printf("ERROR");break;} RED WHITE BLUE RED ERROR RED WHITE BLUE ERROR ERROR RED TRUE ANSWER : ? YOUR ANSWER : ?
Which of the following statements are correct about an array?1. The array int num[26]; can store 26 elements.2. The expression num[1] designates the very first element in the array.3. It is necessary to initialize the array at the time of declaration.4. The declaration num[SIZE] is allowed if SIZE is a macro. 1, 4 2, 4 2, 3 1 None of these TRUE ANSWER : ? YOUR ANSWER : ?
What will be the output of the following program code?main(){ static int var = 5; printf("%d ", var--); if(var) main();} Compilation Error None of these 5 4 3 2 1 5 5 5 5 5 Infinite Loop TRUE ANSWER : ? YOUR ANSWER : ?
Determine Output:void main(){ int i=0; for(;i++;printf("%d", i)); printf("%d", i);} Error 12 1 11 TRUE ANSWER : ? YOUR ANSWER : ?
What will be the output of the following program? #include\<stdio.h> int main(){ extern int i; i = 20; printf("%ld ", sizeof(i)); return 0; } 2 Depends on the Compiler 4 Linker Error : Undefined symbol 'i' TRUE ANSWER : ? YOUR ANSWER : ?
#include<stdio.h>void main(){ int *ptr, a=10; ptr = &a; *ptr += 1; printf("%d, %d", *ptr, a);} 10, 10 11, 11 11, 10 10, 11 TRUE ANSWER : ? YOUR ANSWER : ?
The function scanf() returns ......... The actual values read for each argument. 1 ASCII value of the input read. The number of successful read input values. 0 TRUE ANSWER : ? YOUR ANSWER : ?
Determine Output:void main(){ char *p; printf("%d %d", sizeof(*p), sizeof(p));} 2 2 1 2 1 1 2 1 TRUE ANSWER : ? YOUR ANSWER : ?
Determine Output:void main(){ static char *s[] = {"black", "white", "yellow", "violet"}; char **ptr[] = {s+3, s+2, s+1, s}, ***p; p = ptr; ++p; printf("%s",*--*++p + 3); } ow te ck et TRUE ANSWER : ? YOUR ANSWER : ?
What will be printed after execution of the following program code?main(){ printf("\\nab"); printf("\\bsi"); printf("\\rha"); } None of these asiha hai haasi absiha TRUE ANSWER : ? YOUR ANSWER : ?