/** * 31天的 1, 3, 5, 7, 8, 10 ,12 30天的 4, 6,9,11 28天(平年) 2 29天(闰年) 2 */ class Demo{ public static void main(String[] args){ //年数 int n = 2015; //月数 int y =3; //天数 int t =0; switch(y){ case 1: case 3: case 5: case 7: case 8: case 10: case 12: t = 31; b…