How can I write a Java program to print the season name based on the month number using if statemnt
Answers
Answered by
0
Answer:
Dear Mate !
Explanation:
package season;
public class Seasons {
public void month_Season(int month){
if(month>0 && month<=12){
if(month==2){System. out. println(“Spring”);}
else if(month>2 && month<=5){System. out. println(“Summer”);}
else if(month>5 && month<=9){System. out. println(“Monsoon”);}
else if(month>9 && month<=11){System. out.
Hope this answer helps you.
Mark this answer as brainliest answer.
Similar questions