what is the different between if-else and switch statment
(other than syntax)
Answer Posted / fazlur rahaman naik
The main difference between switch - case and if - else is
we can't compare variables.
in the if - else, first the condition is verified,then it
comes to else whereas in the switch - case first it checks
the cases and then it switches to that particular case.
| Is This Answer Correct ? | 168 Yes | 35 No |
Post New Answer View All Answers
What are the features of the c language?
Why do we need volatile in c?
What are the advantages of using Unions?
i have a written test for microland please give me test pattern
What is extern c used for?
Differentiate between a structure and a union.
which of the following is not a character constant a) 'thank you' b) 'enter values of p, n ,r' c) '23.56E-o3' d) all of the above
Explain what standard functions are available to manipulate strings?
What does c mean in standard form?
Can static variables be declared in a header file?
Can i use “int” data type to store the value 32768? Why?
Explain what is the difference between a string copy (strcpy) and a memory copy (memcpy)? When should each be used?
What is structure in c language?
what is the height of tree if leaf node is at level 3. please explain
how to write a c program to print list of fruits in alpabetical order?