How to set JDK path in windows

JDK (Java Development Kit) is a software development kit for Java programming language, provided by Oracle Corporation. It includes a Java Runtime Environment (JRE), development tools like the Java compiler and debugger, and additional libraries and tools for developing Java applications.

To set the JDK path in Windows:

  1. 1. Download and install the JDK from the Oracle website.

  2. 2. Right-click on "My Computer" and select "Properties".

  3. 3. In the System Properties, click on the "Advanced" tab and then click on the "Environment Variables" button.

  4. 4. In the Environment Variables window, scroll down to the "System Variables" section and look for "JAVA_HOME". If it doesn't exist, click on the "New" button and add a new variable with the name "JAVA_HOME" and the value of the JDK installation directory (e.g. "C:\Program Files\Java\jdk1.8.0_251").

  5. 5. Scroll down to the "Path" variable, click on "Edit", and add the JDK bin folder to the end of the value (e.g. ";C:\Program Files\Java\jdk1.8.0_251\bin").

  6. 6. Click on "OK" to close all windows.

  7. 7. To check if the JDK path is set correctly, open a Command Prompt window and type "java -version". It should display the version of the JDK installed on your system.

Note: The steps may vary slightly based on the version of Windows you are using.