A switch statement allows a variable to be tested for equality against a list of values. Each value is called a case, and the variable being switched on is checked for each case.if variable and case value are matched, then matched case will be executed. we can also say :- The switch statement is a multiway branch statement. It provides an easy way to dispatch execution to different parts of code based on the value of the expression.
This is a companion discussion topic for the original entry at http://iq.opengenus.org/switch-case-control-statement/