In this c programming video tutorial you will learn to use Range in the switch statement case values with example.

using the Range feature starts at @6:31

GCC Compiler allows you to use this feature. usage of the range in the case values of the switch statement allows the programmer to execute a set of statements for a range of values.

Syntax for using the Range in switch case values
case LowerLimit … upperlimit:

while using this feature you have to follow 2 rules.
LowerLimit can not be greater than the upperlimit.
none of the cases should contain overlapping values ( one value should not have matches in 2 or more cases ).

#c-programming

Using Range in the Case Values of Switch Statement | C Programming Video Tutorial
1.75 GEEK