Home > Java > javaTutorial > How to configure Java environment variables in Windows

How to configure Java environment variables in Windows

PHPz
Release: 2023-05-02 14:22:06
forward
5038 people have browsed it

1. Configure the JAVA_HOME environment variable

  • Variable name: JAVA_HOME

  • Variable value: C :\Program Files\Java\jdk1.8.0_311

2. Configure the Path environment variable

  • Variable name: Path

  • Variable value: %JAVA_HOME%\bin or C:\Program Files\Java\jdk1. 8.0_311\bin

3.Verification

>java -version
java version "1.8.0_311"
Java(TM) SE Runtime Environment (build 1.8.0_311-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.311-b11, mixed mode)
 
>javac -version
javac 1.8.0_311
 
>echo %JAVA_HOME%
C:\Program Files\Java\jdk1.8.0_311\bin
Copy after login

The above is the detailed content of How to configure Java environment variables in Windows. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:yisu.com
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template