說(shuō)是運(yùn)行正確,輸出錯(cuò)誤
public class HelloWorld{ public static void main(String[] args){ int num = 999; int count = 0; for(count=0;(num/=10)==0;count++){ ?System.out.println("它是個(gè)"+count+"位數(shù)!"); } } }輸出哪里錯(cuò)啦?
public class HelloWorld{ public static void main(String[] args){ int num = 999; int count = 0; for(count=0;(num/=10)==0;count++){ ?System.out.println("它是個(gè)"+count+"位數(shù)!"); } } }輸出哪里錯(cuò)啦?
2018-02-06
舉報(bào)
2018-02-06
把“位數(shù)”改成“位的數(shù)”。
運(yùn)行正確說(shuō)民代碼成功運(yùn)行沒(méi)有出錯(cuò)。輸出錯(cuò)誤說(shuō)明沒(méi)有輸出題目期望的結(jié)果。要一字不落地符合才可以。
話(huà)說(shuō)回來(lái),你只有一行代碼
也會(huì)判定你為運(yùn)行成功
2018-02-06
public class HelloWorld{
? ? public static void main(String[] args){
? ? ? ? int num = 999;
? ? ? ? int count = 0;
? ? ? ? for(count=0;(num/=10)==0;count++){
? ? ? ? System.out.println("它是個(gè)"+ count+"位的數(shù)!");
? ? ? ? ? ? }
? ? ? ? ? ? }
? ? ? ? ? ? }
可是為什么改完之后還是沒(méi)好?