Table of Contents
To Windows
After you’ve installed the Java Development Kit(JDK) in Windows, you must set the path in Java Environment variable to point out the JDK installation directory.
Default drive is Programming file in C Drive.
If you save the java source file inside the JDK/bin folder, this path is not required. Otherwise, if you save java source file in any other directory or folder(out side of the JDK/bin folder), it is required to set path to compile and run the java program.
There are 2 methods to set java path
set psth= C:Program FilesJavajdk1.8.0_45bin
if you like setting the permanent path of JDK, you must consider the following steps
1. Open my computer, click right mouse button and select properties
2. Click on Advanced system setting
Click on Environment Variable
Click the new button in the user variable
Write path in Variable name
Copy the path or Address of JDK bin folder
Paste path of bin folder in Variable value then click ok button
Then click on ok button
Then click OK button
Ok you set permanent path of Java for the run and compile on your PC
Related post
Multiply two numbers in Java using scanner| 5 different ways In this article, we will…
5 Different ways to Divide two numbers in Java using scanner In this article, we…
Learn 8 Ways to Subtract Two Numbers Using Methods in Java In this article, we…
10 ways to subtract two numbers in Java In this article, we will discuss the…
Java Code Examples – Multiply Two Numbers in 5 Easy Ways In this article, we…
How to Divide two numbers in Java| 5 different ways In this article, we will…
This website uses cookies.