我就想知道跟答案是一樣的為什么執行不出來?
public?class?HelloWorld?{
????public?static?void?main(String[]?args)?{
int?age=25;
????????if?(age?>?60)?{
????????System.out.println("老年");????
????????}
????else?if(age?>?40)?{
????????System.out.println("中年");????
????????}
????else?if(age?>?18)?{
????????System.out.println("少年");
????????}
????else??????????????{
????????System.out.println("童年");?
????}????
????
?
????
}
}
2018-04-13
age > 40和age > 18的左括號是中文括號,改成英文的就行
2018-03-29
我的也是這樣 看看問答原來和我有一樣的
2018-02-05
你的符號全是英文符號嗎 比如括號什么的