Java examples for Object Oriented Design:Method
Writing to the output the arguments of the invoked main function
public class Main{ public static void main(String[] args) { for (int i = 0; i < args.length; i++) System.out.println(i + ":" + args[i]); }// ww w. j a v a 2 s.c o m }