C Programming :: Control Instructions - Discussion
Home > C Programming > Control Instructions > MCQs Questions Discussion
511 / 33
Predict the output of following code:
#include <stdio.h>
void main()
{
int a=2;
switch(a)
{
case 1: printf("one");
case 2: printf("Two");
case 3: printf("Three");
default:printf("Invalid option");
}
}
#include <stdio.h>
void main()
{
int a=2;
switch(a)
{
case 1: printf("one");
case 2: printf("Two");
case 3: printf("Three");
default:printf("Invalid option");
}
}
Aonetwothree
BInvalid option
Cone two
DTwoThreeInvalid option
ENone of these
Answer: Option (Login/Signup)
Show Explanation
Asked In ::
No Discussion on this question yet!