Java is a statically-typed, object-oriented programming language that powers everything from Android apps to large-scale enterprise backends (including most systems built with Spring Boot, which we’ll cover later in its own course).
Tip: you don't need to memorize syntax up front. Focus on understanding how a Java program is structured, then build muscle memory through practice.
Your first Java program
Every Java program starts with a class and a main method — this is the entry point the Java Virtual Machine (JVM) looks for when it runs your code.
public class HelloWorld {
public static void main(String[] args) {
System.out.println("Hello, World!");
}
}
A few things to notice:
- The class name (
HelloWorld) must match the filename (HelloWorld.java). public static void main(String[] args)is the fixed signature the JVM expects — this exact line rarely changes across projects.System.out.println(...)prints a line of text to the console.
What’s next
In the next lesson, we’ll break down Java’s basic syntax rules: variables, data types, and how statements are structured.