The Quintessential Java Application

The parameters to the application are made available in args. This example simply prints out Hello World!.
public class BasicApp { public static void main(String[] args) { // Process each parameter for (int i=0; i<args.length; i++) { // process args[i]; } // Output a message to the console System.out.println("Hello World!"); } }
Here's the command to run the program:
> java BasicApp param1 param2 ...

Post a comment

More information about formatting options

CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.
Image CAPTCHA
Enter the characters shown in the image. Ignore spaces and be careful about upper and lower case.