#include
main()
{
int i=1,j=2;
switch(i)
{
case 1: printf("GOOD");
break;
case j: printf("BAD");
break;
}
}
Answer Posted / suresh reddy
Compiler Error: Constant expression required in function
main
instead of using j u we can use case 'j' .
this is correct answer
Is This Answer Correct ? | 5 Yes | 5 No |
Post New Answer View All Answers
Subtract Two Number Without Using Subtraction Operator
Explain what would happen to x in this expression: x += 15; (assuming the value of x is 5)
Where in memory are my variables stored?
int far *near * p; means
explain what is an endless loop?
What is nested structure?
An expression to whose value an operater is applied a) operand b) variable c) constant d) all of the above
What are the __date__ and __time__ preprocessor commands?
What is restrict keyword in c?
What is structure in c language?
what is reason of your company position's in india no. 1.
Tell me when would you use a pointer to a function?
When should a type cast not be used?
What is the explanation for the dangling pointer in c?
What is the difference between malloc() and calloc() function in c language?