How do I set or change the PATH system variable?
Reopen Command prompt window, and run your java code. Mac OS X. To run a different version of Java, either specify the full path, or use the java_home toolIf the version is old or you get the error java: Command not found then the path is not properly set.