标签:sys print int while循环 system out while i++ for循环
int sum=0;
for (int i = 100; i>=1; i--) {
sum+=i;
}
System.out.println(sum);
int sum=0;
int i = 1;
while(i<=100) {
sum+=i;
i++;
}
int sum=0;
int i=1;
do {
sum+=i;
i++;
}while(i<=100);
标签:sys print int while循环 system out while i++ for循环
原文地址:https://www.cnblogs.com/fengxia/p/10202484.html