package src1;
import java.util.Scanner;
class addse{
private int year;
private int month;
private int day;
public addse(int a,int b,int c) {
year=a;
month=b;
day=c;
}
public int getAge() {
int get,set;
get=year-2017;
if(month==12&&day>25) {
set=get+1;
} else {set=get;}
return set;
}
}
public class s79 {
Scanner input=new Scanner(System.in);
int f=input.nextInt();
int g=input.nextInt();
int h=input.nextInt();
addse a1=new addse(f,g,h);
System.out.println("age="+a1.getAge());
}
这个System这个语句是错误的请问下为什么哪里错了