作业帮 > 综合 > 作业

各位前辈们来看看:class monthcounter{ public static void main(String

来源:学生作业帮 编辑:搜狗做题网作业帮 分类:综合作业 时间:2024/05/25 14:50:47
各位前辈们来看看:
class monthcounter
{
public static void main(String [] args)
{
int intyearmonth01=200907;
int intyearmonth02=198811;
int intyear01,intyeat02,intmonth01,intmonth02;
intyear01=intyearmonth01/100;
intyear02=intyearmonth02/100;
intmonth01=intmonthmonth01%100;
intmonth02=intmonthmonth02%100;
int xmonth;
xmonth=(intyear02-intyear01)*12+(intmonth02-intmonth01);
System.out.println(intyearmonth01+"与"+intyearmonth02+"之间相差"+xmonth+"月");
}

}
这个小程序哪出问题咯,就是编译不能通过出现cannot resolve symbol这错误monthcounter.java:9: cannot resolve symbol
symbol : variable intyear02
location: class monthcounter
intyear02=intyearmonth02/100;
拜托大家啦!先谢上.
各位前辈们来看看:class monthcounter{ public static void main(String
int intyear01,intyeat02,...
intyear02=...
对比一下第7个字母