MCQOPTIONS
Bookmark
Saved Bookmarks
→
C Programming
→
Floating Point Issues
→
Which of the following cannot be checked in a swi...
1.
Which of the following cannot be checked in a switch - case statement?
A.
Character
B.
Integer
C.
Float
D.
enum
Answer» D. enum
Show Answer
Discussion
No Comment Found
Post Comment
Related MCQs
What will be the output of the following C code?#include <stdio.h> int main() { int n = 1; switch (n) { case n: printf("Case N "); default: printf("Default"); } }
Which of the following statement are correct about the program given below?#include <stdio.h>int main ( ){ int x = 10, y = 20; if (x == 15) && if (y == 20) printf ("Have a nice day n"); return 0;}
Which of the following statement are correct about the program given below?#include <stdio.h>int main ( ){ int a = 40, b = 50; if ( a == b ) printf ("a is equal to b n"); elseif (a > b) printf ("a is greater than b n"); elseif (a < b) printf ("a is less than b n"); return 0;}
Which of the following is the correct output for the program given below?#include <stdio.h>int main (){ int a = 400, b, c; if ( a >= 500) b = 400; c = 300; printf ( "%d %d %d n" , a, b, c); return 0;}
Which of the following is the correct output for the program given below ?#include <stdio.h>int main ( ){ int k = 5; switch (k) { case 1: printf ("Good Morning n"); case 2: printf ("Good Evening n"); break; case 3: continue; default: printf ("Bye n"); } return 0;}
Which of the following cannot be checked in a switch - case statement?
What will be the output of the following C code? (Assuming that we have entered the value 1 in the standard input).#include <stdio.h> void main() { char *n; printf("Enter a value between 1 to 3:"); scanf("%s", n); switch (n) { case "1": printf("Hey"); break; case "2": printf("Hello"); break; } }
Comment on the output of the following C code. #include <stdio.h> int main() { int num = 2; switch (num) case 1: printf("%d", num); case 2: printf("%d", num); case 3: printf("%d", num); default: printf("%d", num); }
What will be the output of the following C code?#include <stdio.h> #define max(p) p int main() { int n = 1; switch (n) { case max(2): printf("Right... n"); case max(1): printf("Wrong... n"); break; } }
What will be the output of the following C code? (Assuming that we have entered the value 1 in the standard input).#include <stdio.h> void main() { double var; printf("Enter a value between 1 to 2:"); scanf("%lf", &var); switch (var) { case 1: printf("1"); break; case 2: printf("2"); break; } }
Reply to Comment
×
Name
*
Email
*
Comment
*
Submit Reply
Your experience on this site will be improved by allowing cookies. Read
Cookie Policy
Reject
Allow cookies