Computer Science, asked by hiyapansuriya, 6 months ago

how is if else if more general than switch case​

Answers

Answered by uditagupta2020
9

The switch case is more compact than lot of nested else if. ... Another difference between switch case and else if ladder is that the switch statement is considered to be less flexible than the else if ladder, because it allows only testing of a single expression against a list of discrete values.

Similar questions