Introduction to Java · Introduction to Java Programming

Parts of Java

Watch lectures

Parts of Java

1. Beginner Big Picture

Java = Language + Platform. Language is syntax you type; platform (JVM + API) is what runs it.

Part What it is Example
Java Language keywords, syntax, OOP rules class, if, for
JDK (tools) compiler + runner + debugger javac, java, javadoc
JRE (runtime) JVM + standard libraries to run apps install JRE to run, JDK to develop
JVM engine executing bytecode HotSpot JVM
Java API (libraries) ready-made classes String, ArrayList, Scanner
IDE / Build helpers (not part of language) IntelliJ, Eclipse, Maven

2. Minimal Program Anatomy (every word explained)

public class Hello {           // file Hello.java, class = blueprint
    public static void main(String[] args) { // entry: JVM calls this first
        System.out.println("Hi"); // API call: print line
    }
}
  • public → visible to JVM. class → container. static → no object needed. void → returns nothing. String[] args → command-line inputs.

3. Compile-Run Chain

Hello.java --javac--> Hello.class --java Hello--> output Hi

4. Beginner Mistakes

  • File name must match public class (Hello ↔ Hello.java), case-sensitive.
  • No main → Main method not found error.
  • One public class per file (beginner rule).

5. Exam Points

  • Java language vs platform, JDK vs JRE vs JVM — 5 marks, very frequent.
  • Explain each word of main — 3-5 marks, frequent.
Student FinanceWeb Platform

Pocketly — Personal Finance for Students

Keep your hostel and college expenses under control. Track accounts, log spending in seconds, and stay within your monthly budget.

← All Introduction to Java Programming modules