Java Program to Define Ordinal() Method Using Enum Concept
Java enum, also called Java enumeration type, is a type whose fields consist of a fixed set of constants. The java.lang.Enum.ordinal() tells about the ordinal number(it is the position in its enum declaration, where the initial constant is assigned an ordinal of zero) for the particular enum. ordina