What is an environment variable?
Environment variables usually refer to the operating system to specify some of the parameters that the operating system needs to run. Typically a series of key-value pairs.
The role of the PATH environment variable
The PATH environment variable is the operating system external command search path
What is an external command search path? For example, if you execute the ipconfig command under CMD, display the current computer network card configuration. When the input ipconfig, the operating system will perform Ipconfig.exe (C:\Windows\System32), that is, when you enter the XXX command, the system will execute the corresponding EXE, in the path of the variable value in turn look for the EXE's storage path, can not find the hint error.
The role of CLASSPATH environmental variables
The CLASSPATH environment variable is the class file search path. The variable value of the CLASSPATH environment variable is the point, and the point represents the current directory.
When the Java Hello command is executed, the program looks for hello.class files in the current directory
What's inside the JDK? The directory is as follows
Bin folder: All commands required to use Java, such as
Javac: Compiling, translating the source code into code that is understandable to the computer
Include folder: Put some C-language programs
JRE folder: Java Runtime Environment
Lib folder: Package files required by Java
Src.zip:java JDK part of source files
What is a JRE?
The JRE is the Java Runtime Environment,java runtime environment, including Java Virtual machines (JVMS), Java platform Core class files, and other supporting files.
What is a JVM?
The JVM is the acronym for Java Virtual Machine, a computer that is virtualized by software.
The programmer writes Java source files (. java), the compiler checks the source file for syntax errors, compiles the byte code (. Class) file without errors, and runs on any virtual machine. For different operating systems there are different virtual machines, the virtual machine to compile the class file into the current operating system code, and then by the operating system to the hardware to execute. Two times compiled