标签:style color java for ar new c public
public class NewDemo01 {
public static void main(String[] args) {
System.out.print("No args(fun()):");
fun();
System.out.print("\n one args(fun()):");
fun(1);
System.out.print("\n five args(fun()):");
fun(1, 2, 3, 4, 5);
}
private static void fun(int... arg) {
for (int i = 0; i < arg.length; i++) {
System.out.print(arg[i] + "\t");
}
}
}
标签:style color java for ar new c public
原文地址:http://www.cnblogs.com/vonk/p/3885107.html