SELF
Exam
Programming
switch(option)
{
case 'H' : printf("Hello");
case 'W' : printf("Welcome");
case 'B' : printf("Bye");
break;
}
what would be the output if option = 'H' ?
Read Solution (Total 2)
-
- output: HelloWelcomeBye because in switch case all the cases get executed from the true case until it get break condition in any case
- 10 years agoHelpfull: Yes(0) No(0)
- HelloWelcomeBye
- 5 years agoHelpfull: Yes(0) No(0)
SELF Other Question