Java Switch Statement.

In Java, switch statement enables you to execute a block of code based on the value of some variable.

Code :