重生之盾御苍穹免费:java 我是初学者

来源:百度文库 编辑:高校问答 时间:2024/04/29 10:42:02
我想把这段程序用JSP显示出来,用什么方法呢!请高手帮忙!
重谢!
public class add {

/**
* @param args
*/
public static void main(String[] args) {
// TODO Auto-generated method stub
int a=0 ;
int b=1 ;
do {a=a+b; b++;}
while (b<11);
System.out.println("1+2+3+4+5+6+7+8+9+10=" + a + "." );
}

}