下面是一个例子:
int i = 0;
do{
if(i == 5)
// Won't print 5 but instead go back to the "top" of do
// but first, will execute the while verification
continue;
System.out.println(i);
}while(i++ < 10);
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
1957 次 |
| 最近记录: |