标签:oid ++ 初始 pack color void system ati for
package myproject; public class TestWhile { public static void main(String[] args) { //while循环 int b=1;//初始化 while(b<=10) {//条件判断 System.out.println(b);//循环体 b++;//迭代 } //for循环 for (int i=1;i<=10;i++) { //循环体结束后,再迭代 System.out.println(i); } int a=1; int sum=0; while(a<100) { sum+=a; a++; } System.out.println("sum:"+sum); } }
标签:oid ++ 初始 pack color void system ati for
原文地址:https://www.cnblogs.com/hapyygril/p/12341694.html