Start Java Program

class mypro {
public static void main(String args[]){
System.out.println("welcome to Aboutcodes");

All java program are start with class. mypro is name of class. The body of class will be between {} braces.

All java application begin execution by calling main().

public is allows the programmer to control the visibility of class members. when class member is defined by public than that member can be accessed by code outside the class.

main() must be declared as public, since it must be called by code outside of its class when program is stated.

static allow main() to be called without having to instantiate a perticular instance of the class. this important Because main() is called by the java virtual machine before any objects are made.

void means no return value. here void tells the compiler that main() does not return a value.

There must be a parameter in main(). if there are no parameter, you still need to include the empty parentheses.

String args[] declares a parameter named args, which is an array of instances of the class String. Objects of type String store character strings. In this case, arg receives any command line arguments present when the program is executed.

println is used to display welcome to aboutcodes.

# main() is different from Main().
# System and String are not system and string, S much be capital.

List Code:-
Java codes

Next Code:-
Run Java Program

Java Programs:-
List of Java Programs


  1. I am glad that I saw this post. It is informative blog for us and we need this type of blog thanks for share this blog, Keep posting such instructional blogs and I am looking forward for your future posts. Python Projects for Students Data analytics is the study of dissecting crude data so as to make decisions about that data. Data analytics advances and procedures are generally utilized in business ventures to empower associations to settle on progressively Python Training in Chennai educated business choices. In the present worldwide commercial center, it isn't sufficient to assemble data and do the math; you should realize how to apply that data to genuine situations such that will affect conduct. In the program you will initially gain proficiency with the specialized skills, including R and Python dialects most usually utilized in data analytics programming and usage; Python Training in Chennai at that point center around the commonsense application, in view of genuine business issues in a scope of industry segments, for example, wellbeing, promoting and account. Project Center in Chennai


Add your comments here

Back to Top