Beruflich Dokumente
Kultur Dokumente
Main method in Java is the first programming method a Java programmer knows when he starts
learning Java programming language.have you ever thought about why main method in Java is
public, static and void, of-course Yes, since most of us first learn C and C++ than we move to Java
in our programming path we familiar with main method but in Java main method is slightly different it
doesn't return any value like in C it returns int, main method is public static and void Why? In this
post we will try to find answer of these questions and have an idea of one of the most popular
questions in Java why main method is declared Static.