#include
main()
{
int i=1,j=2;
switch(i)
{
case 1: printf("GOOD");
break;
case j: printf("BAD");
break;
}
}
Answer Posted / shruti
nopes we cannot use 'j'... because single qutoes ' ' are
used only for character value.. i.e if it was
char i
switch(i)
then we cud have used it like that..
hence in our case,
it will give a compiler error...
| Is This Answer Correct ? | 3 Yes | 3 No |
Post New Answer View All Answers
What does double pointer mean in c?
When the macros gets expanded?
Why cant I open a file by its explicit path?
What is spark map function?
Is javascript based on c?
What is "Hungarian Notation"?
Describe explain how arrays can be passed to a user defined function
Does * p ++ increment p or what it points to?
When should a type cast not be used?
Which is the best website to learn c programming?
How can I find out how much free space is available on disk?
Can we add pointers together?
How can I do peek and poke in c?
What is the value of uninitialized variable in c?
Is boolean a datatype in c?