The enumeration type is a data type of a constant collection, and the enumeration constant can be used in any place where the constant can be used, such as the case label in the switch statement, and the control enhanced for statement.
A sample program using an enumeration type in a switch statement.