Go to your Java install directory and then the bin directory. Then type java -version. It should print the java version. You can add that directory to your path environment variable which allows you to access Java from anywhere on your pc.
"Any fool can write code that a computer can understand. Good programmers write code that humans can understand." --- Martin Fowler
Please correct my English.