//write your code here
if (month >= 12) {
System.out.println("winter " + "(12)");
}
if (month > 10) {
System.out.println("spring " + "(4)");
}
if (month < 7) {
System.out.println("summer " + "(7)");
}
if (month <= 4) {
System.out.println("autumn " + "(10)");
}
}
}
package com.codegym.task.task04.task0411;
/*
Seasons on Terra
*/
public class Solution {
public static void main(String[] args) {
checkSeason(12);
checkSeason(4);
checkSeason(7);
checkSeason(10);
}
public static void checkSeason(int month) {
//write your code here
if (month >= 12) {
System.out.println("winter " + "(12)");
}
if (month > 10) {
System.out.println("spring " + "(4)");
}
if (month < 7) {
System.out.println("summer " + "(7)");
}
if (month <= 4) {
System.out.println("autumn " + "(10)");
}
}
}