課程
/后端開發(fā)
/Java
/Java入門第一季(IDEA工具)升級版
哪里錯了大神
2018-08-15
源自:Java入門第一季(IDEA工具)升級版 4-1
正在回答
慕UI4435186 提問者
public?class?HelloWorld?{ ????public?static?void?main(String[]?args)?{ ????????int?one?=?20; ????????if(ont?%?2?==?0){ ????????System.out.println("one是偶數(shù)"); ????????} ????} }
println,你這個代碼在編譯的時候就會指出錯誤
System.out.println("one是偶數(shù)");
if條件語句少了一對大括號,雖然能運(yùn)行但是代碼最好寫的規(guī)范點(diǎn)=-=
少個t
舉報
0基礎(chǔ)萌新入門第一課,從Java環(huán)境搭建、工具使用、基礎(chǔ)語法開始
2 回答public class HelloWorld{ public static void main(String[] args) { int one = 10 ; int two = 20 ; int three = 0 ; int a =one+two; int b =two*2; int c =(two*2)-one; int d =two*=one; int f =two/
2 回答public class HelloWorld{ public static void main(String[] args) { System.out.println(hobby); } }
1 回答public class HelloWorld! { public static void main(String[] args) { System.out.println("hello imooc"); } }
4 回答public class HelloWorld!{ public static void main(String[] args) { System.out.println("Hello Imooc"); } }
10 回答public class HelloWorld{ public static void main(String[]args){ int i=1; int sum=0; for(;i<=10;i++){ if(i%2!=0){ continue; } sum=sum+i; } System.out.println("1
Copyright ? 2025 imooc.com All Rights Reserved | 京ICP備12003892號-11 京公網(wǎng)安備11010802030151號
購課補(bǔ)貼聯(lián)系客服咨詢優(yōu)惠詳情
慕課網(wǎng)APP您的移動學(xué)習(xí)伙伴
掃描二維碼關(guān)注慕課網(wǎng)微信公眾號
2018-08-15
println
2018-08-15
2018-08-15
println,你這個代碼在編譯的時候就會指出錯誤
2018-08-15
System.out.println("one是偶數(shù)");
2018-08-15
if條件語句少了一對大括號,雖然能運(yùn)行但是代碼最好寫的規(guī)范點(diǎn)=-=
2018-08-15
少個t