循环结构
Q:常见的循环结构有哪些?
-
A:
-
while循环
-
do...while循环
-
for循环
-
forEach循环
int [] nums =new int{1,2,3,4,5}
for(int num :nums){
System.out.println(x)
}
-
A:
while循环
do...while循环
for循环
forEach循环
int [] nums =new int{1,2,3,4,5}
for(int num :nums){
System.out.println(x)
}