What it mean?

A java programe always start with the statment

"public void main (String[]argument)"

i know it mean the programe start from here, but i don't know what the words mean.

would you please tell me what do"public", "void", and "(String[]argument)"means ? I'll very appreciate

[312 byte] By [AlexandraT] at [2007-9-26 1:32:46]
# 1

public = access by anyone

void = does not have return value

main = beginning of program i.e. start here

(String[] argument) = Array to hold command line items that may be typed when starting program.

Example: If you program opens a file for reading you may need to supply the name of the file, size of file, type of file).

String[] Arguement holds these values. They can then be accessed like any other array.

Good luck.

GLJdotcom at 2007-6-29 1:34:16 > top of Java-index,Archived Forums,New To Java Technology Archive...
# 2
http://java.sun.com/docs/books/tutorial/getStarted/application/main.html
thomasfly at 2007-6-29 1:34:16 > top of Java-index,Archived Forums,New To Java Technology Archive...