• Post Reply Bookmark Topic Watch Topic
  • New Topic

main()

 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
why main() is declared static
 
Ravee Bhat
Ranch Hand
Posts: 72
Eclipse IDE Firefox Browser Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
static methods are accessible before the instance of the class is present. So this way the main method is available to the jvm for creation of the objects.
regards
ravee.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!