New course! Every coder should learn Generative AI!
Try a free lesson+ 2
You can follow this pattern...
public enum Season { WINTER, SPRING, SUMMER, FALL }
class EnumExample2{
public static void main(String[] args) {
Season s=Season.WINTER;
System.out.println(s);
}}