Downloading and Installing JDK on Windows

This section describes how to download and install JDK on a Windows system.

To learn Java, you need to have JDK installed on your computer. If you are Windows user, you can follow what I did to download and install JDK 17 on your Windows computer.

1. Open the Java SE Download page with this URL: https://www.oracle.com/java/technologies/downloads/.

2. Click the "Windows" tab under the "Java SE Development Kit 17.0.1 downloads". You will see a new page with a list of different download files of JDK 17.

3. Click the hyper link of "https://download.oracle.com/java/17/latest/jdk-17_windows-x64_bin.exe", next to "x64 Installer 152 MB".

4. Save jdk-17_windows-x64_bin.exe to a temporary directory.

5. Double-click on jdk-17_windows-x64_bin.exe to start the installation wizard.

6. Follow instructions on the installation wizard to finish the installation.

The picture below shows you how the JDK 17 Installation Screen looks like:

JDK 17 Installation Screen
JDK 17 Installation Screen

To test the installation, open a command window to try the java command. If you are getting the following output, your installation is good:

herong> \progra~1\java\jdk-17.0.1\bin\java -version

java version "17.0.1" 2021-10-19 LTS
Java(TM) SE Runtime Environment (build 17.0.1+12-LTS-39)
Java HotSpot(TM) 64-Bit Server VM 
  (build 17.0.1+12-LTS-39, mixed mode, sharing)

Congratulations, you have successfully installed JDK on your Windows computer!

Table of Contents

 About This Book

JDK - Java Development Kit

 Downloading and Installing JDK on Mac

Downloading and Installing JDK on Windows

 Adding JDK "bin" Directory to Path Setting

 Downloading and Installing JDK on Linux

 Writing My First Java Program

 JDK Documentation Installation

 Execution Process, Entry Point, Input and Output

 Primitive Data Types and Literals

 Control Flow Statements

 Bits, Bytes, Bitwise and Shift Operations

 Managing Bit Strings in Byte Arrays

 Reference Data Types and Variables

 Enum Types and Enum Constants

 StringBuffer - The String Buffer Class

 System Properties and Runtime Object Methods

 Generic Classes and Parameterized Types

 Generic Methods and Type Inference

 Lambda Expressions and Method References

 Java Modules - Java Package Aggregation

 Execution Threads and Multi-Threading Java Programs

 ThreadGroup Class and "system" ThreadGroup Tree

 Synchronization Technique and Synchronized Code Blocks

 Deadlock Condition Example Programs

 Garbage Collection and the gc() Method

 Assert Statements and -ea" Option

 Annotation Statements and Declarations

 Java Related Terminologies

 Archived Tutorials

 References

 Full Version in PDF/EPUB