It is widely required for java based programmings without setting this you will get errors while doing programming stuff.
Here you have to set the path of JDK and JRE. Before configuring the path of environments variables you must have to install JDK and JRE on your PC.
After installing JDK and JRE than only go for the further process of configuration.
Step1: Right click on your My Computer or This PC. You can even press Alt + Enter = Properties.
Step5: Now click on “New” type JAVA_HOME on the first input field and below that set JDK path.