Module 1: Getting Started
Introduction to Java
What Java is, how it runs, and where it is used.
Java is a general-purpose programming language used to build backend services, enterprise applications, Android applications, and many other kinds of software. It is designed to let developers write a program once and run it on systems that have a compatible Java runtime.
How Java code runs#
Java source code is usually saved in a file ending in .java. The Java compiler converts it into bytecode, normally stored in a .class file. The Java Virtual Machine (JVM) executes that bytecode.
Java source (.java) -> compiler (javac) -> bytecode (.class) -> JVM -> program runs
Three terms are useful to distinguish:
- JDK (Java Development Kit): tools for developing Java applications, including the compiler.
- JVM (Java Virtual Machine): executes Java bytecode.
- JRE (Java Runtime Environment): the runtime components needed to run Java applications; its packaging varies across modern Java distributions.
Why learn Java?#
Java has static types, automatic memory management, a mature standard library, and a broad ecosystem. It is commonly used for backend development with frameworks such as Spring Boot. The language also teaches concepts that transfer to many other object-oriented languages.
What you will learn in this course#
Start by installing a JDK and running a small program. Then learn variables, data types, operators, conditions, and loops. The later modules introduce classes, objects, constructors, inheritance, polymorphism, abstraction, and interfaces.
Quick check#
What runs Java bytecode?
The JVM runs Java bytecode. The Java compiler (javac) converts source code into bytecode; it is not the runtime itself.