标签:enum break 基本 win sea java void class inter
出于对自己基础的稳打,期末考试后依旧对SE部分进行复习
public enum Season { SPRING,SUMMER,AUTUMN,WINTER }
public class Test { public static void main(String[] args) { Season a=Season.SPRING; switch (a) { case SPRING: System.out.println("春天"); break; case SUMMER: System.out.println("夏天"); break; case AUTUMN: System.out.println("秋天"); break; case WINTER: System.out.println("冬天"); break; } } }
标签:enum break 基本 win sea java void class inter
原文地址:https://www.cnblogs.com/littlepage/p/10317736.html