In the following control structure which is faster?
1.Switch
2.If-else
and which consumes more memory?
Answer Posted / abhradeep chatterjee
According to me, switch is faster. cause in nested if-
else, the checking occurs in each step. So, more the
compiler checks, the more it takes time. So switch case is
faster.
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
hi any body pls give me company name interview conduct "c" language only
What is the value of a[3] if integer a[] = {5,4,3,2,1}?
How to delete a node from linked list w/o using collectons?
How do you use a pointer to a function?
What is sizeof array in c?
How do you print an address?
When should you not use a type cast?
Can a pointer be static?
write a program to rearrange the array such way that all even elements should come first and next come odd
What is a substring in c?
Tell me the use of bit field in c language?
What are c preprocessors?
Differentiate between the expression “++a” and “a++”?
Describe wild pointers in c?
write a c program to find the largest and 2nd largest numbers from the given n numbers without using arrays