One, JDK installation
JDK version: jdk1.8.0_144 download link: https://pan.baidu.com/s/1eS2bFhg Password: e3q1
After downloading the JDK click Install, you can modify the JDK installation directory as needed, as follows:
For example, I changed the installation directory to: F:\Java\jdk1.8.0_144
Click OK and the next step to complete the installation.
Note: There are two installation prompts during installation, the first is the JDK installation, and the second is the JRE installation. It is recommended that you install them again under the same Java folder.
Complete the post-installation directory:
Second, the environment variable configuration
Open cmd in Run, enter command java-version the description has not been configured for environment variables
Environment variable configuration location: Computer → properties → advanced system settings → advanced → environment variables
1. New environment variable Java_home
Variable name: java_home
Variable value: F:\Java\jdk1.8.0_144 (JDK's installation directory)
2. Modify the variable Path
Increase in the value of the variable:%java_home%\bin;%java_home%\jre\bin;
Note that the original path of the variable value at the end of the number, if not, enter first, and then enter the above code.
3, x new environment variable CLASSPATH
Variable name: CLASSPATH
Variable value:.; %java_home%\lib;%java_home%\lib\tools.jar
Notice that there's a little bit ahead
Open cmd again, enter command java-version
Configuration complete
Installation of JDK on Windows and environment variable settings