#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 %d do?
Why we not create function inside function.
What are the types of functions in c?
What is a static function in c?
What are linker error?
What is %d used for?
What is structure in c language?
Explain the binary height balanced tree?
Explain is it better to bitshift a value than to multiply by 2?
Explain what does the function toupper() do?
Explain with the aid of an example why arrays of structures don’t provide an efficient representation when it comes to adding and deleting records internal to the array.
What is the difference between array and structure in c?
what is the format specifier for printing a pointer value?
What is typedef struct in c?
Give basis knowledge of web designing ...