package com.zxs.process;标签:...,int,process,while,测试,public From: https://www.cnblogs.com/xiaoxiaodeyan/p/17113717.html
public class whileces {
public static void main(String[] args) {
int a=0;
int s=0;
//do...while 先执行,后判断
while (a<=50){
s=s+a;
a++;
}
System.out.println(s);
}
}