问题
单项选择题
下列程序中的循环体将会被执行______。 public class ex7 { public static void main(String[] args) { int n=4; while(n<=8) { System.out.println(n); n++; } } }
A.8次
B.4次
C.2次
D.5次
答案
参考答案:D
下列程序中的循环体将会被执行______。 public class ex7 { public static void main(String[] args) { int n=4; while(n<=8) { System.out.println(n); n++; } } }
A.8次
B.4次
C.2次
D.5次
参考答案:D