作者在 2010-04-06 21:04:16 发布以下内容
package IIOPRMI;
/**
* @author Administrator
*
* TODO To change the template for this generated type comment go to
* Window - Preferences - Java - Code Style - Code Templates
*/
public class sum {
public static void main(String[] args)
{
int summ =0;
if(args.length > 0) {
for (int j=0; j < args.length; j++) {
summ = summ + Integer.parseInt( args[j]);
}
}
System.out.println("sum is :" + summ);
}
}
package IIOPRMI;/**
* @author Administrator
*
* TODO To change the template for this generated type comment go to
* Window - Preferences - Java - Code Style - Code Templates
*/
public class sum {
public static void main(String[] args)
{
int summ =0;
if(args.length > 0) {
for (int j=0; j < args.length; j++) {
summ = summ + Integer.parseInt( args[j]);
}
}
System.out.println("sum is :" + summ);
}
}
/**
* @author Administrator
*
* TODO To change the template for this generated type comment go to
* Window - Preferences - Java - Code Style - Code Templates
*/
public class sum {
public static void main(String[] args)
{
int summ =0;
if(args.length > 0) {
for (int j=0; j < args.length; j++) {
summ = summ + Integer.parseInt( args[j]);
}
}
System.out.println("sum is :" + summ);
}
* @author Administrator
*
* TODO To change the template for this generated type comment go to
* Window - Preferences - Java - Code Style - Code Templates
*/
public class sum {
public static void main(String[] args)
{
int summ =0;
if(args.length > 0) {
for (int j=0; j < args.length; j++) {
summ = summ + Integer.parseInt( args[j]);
}
}
System.out.println("sum is :" + summ);
}
}