// Commanding.java Copyright (c) 2005 Kari Laitinen // http://www.naturalprogramming.com // 2004-10-09 File created. // 2005-11-19 Last modification. // As this is a program that can receive parameters from // the command line, this should be executed in a command // prompt window where the command line parameters can // be given. It may be difficult, and even impossible, to // supply the command line parameters if this program is // executed with a modern development tool such as JCreator // or Eclipse. class Commanding { public static void main( String[] command_line_parameters ) { System.out.print( "\n Method main() was given the following " + command_line_parameters.length + " strings" + "\n as command line parameters: \n" ) ; int parameter_index = 0 ; while ( parameter_index < command_line_parameters.length ) { System.out.print( "\n " + command_line_parameters[ parameter_index ] ) ; parameter_index ++ ; } } }