The switch Statement

By Raul Rios

The switch statement has the following form:

[ ] = optional Example:

The 6 things you must remember about the switch statement are: It works with the following data types: byte/Byte, short/Short, int/Integer, char/Character, String and enum All case labels should be compile time constants (literals or final variables) ..Continue Reading