enum java

Java
public enum AlertLevel {
	Undefined(0),
	Ok(1),
	Warning(2),
	Alarm(3);
}public enum Day {
    SUNDAY, MONDAY, TUESDAY, WEDNESDAY,
    THURSDAY, FRIDAY, SATURDAY 
}
public class MyClass {
  enum Level {
    LOW,
    MEDIUM,
    HIGH
  }

  public static void main(String[] args) {
    Level myVar = Level.MEDIUM; 
    System.out.println(myVar);
  }
}
public class DaysOfTheWeek {

    public enum Days {m, t, w, r, f, sat, s};
  	    public static void main(String[] args) {
          Days d = Days.t; 
          System.out.println(d);
          //the output would be t
        }
}enum Level {
  LOW,
  MEDIUM,
  HIGH
}
//You can access enum constants with the dot syntax:

Level myVar = Level.MEDIUM;enum Color { RED, GREEN, BLUE; } 
public class Main {
    public static void main(String[] args){
        Color c1 = Color.GREEN;
        System.out.println(c1);
    }
}
Source

Also in Java: