System.out.println("\nthe num of the arguments are :" + args.length);
}
}
复制代码
输出结果:
No argument
the num of the arguments are :0
One argument
1
the num of the arguments are :1
Two argument
1, 2
the num of the arguments are :2
Three argument
1, 2, 3
the num of the arguments are :3
false
2