Switch statement is a powerful statement used to handle many alternatives and provides good presentation for C program. But there are some limitations with switch statement which are given below:
Logical operators cannot be used with switch statement. For instance
is not allowed
Switch case variables can have only int and char data type. So float or no data type is allowed.
For instance in the switch syntax given below:
In this ch can be integer or char and cannot be float or any other data type.