Package com.test;
Import Java.util.Scanner;
public class Asgasaf {/** * Enter a certain date of the year, to determine the day is the first days of the year.
* */public static void main (string[] args) {int year;
int mouth;
int day=0;
int days;
Cumulative days int d=0;
int e = 0;
Scanner Scanner = new Scanner (system.in);
do {System.out.println ("Input year:");
Year = Scanner.nextint ();
SYSTEM.OUT.PRINTLN ("Input month:");
mouth = Scanner.nextint ();
SYSTEM.OUT.PRINTLN ("Input day:");
Days = Scanner.nextint ();
if (Mouth < 0 | | mouth > | | Days < 0 | | days >) {System.out.println ("input error!");
e = 1;
} while (E = = 1);
for (int i = 1, i <mouth; i++) {switch (i) {case 1:case 3:case 5:
Case 7:case 8:case 10:case 12: { Day = 31;
Break
Case 4:case 6:case 9:case: {day = 30;
Break
Case 2: {/** * Leap year: ①: The number of hundred years divided by 4, no more than a leap, more than a flat, ② the whole hundred years divided by 400, no more than a leap Yu Ping * February: Excepting 28 days, leap year 29 days */if (year%!=0 &&year% 4 = 0) | | (Year% = = 0 && year%400==0))
{day = 29;
else {day = 28;
}} Default:break;
} D+=day;
System.out.println ("This is" +year+ "year" + (D+days) + "Day"); }
}