This week's book giveaway is in the OCPJP forum.
We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes A question about Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "A question about "main"" Watch "A question about "main"" New topic
Author

A question about "main"

jeff yashero
Greenhorn

Joined: Sep 24, 2003
Posts: 5
Excuse me, could you tell me why the word "main" is not in the keyword-list?
Tom Blough
Ranch Hand

Joined: Jul 31, 2003
Posts: 263
It's not a keyword. You can create variables with the name main. You can create methods with the name main.
It's special only in that the Java Interpreter looks for a public method with the signature main(String[]) and begins execution there.


Tom Blough<br /> <blockquote><font size="1" face="Verdana, Arial">quote:</font><hr>Cum catapultae proscriptae erunt tum soli proscripti catapultas habebunt.<hr></blockquote>
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: A question about "main"