JDK Download and Installation tutorials

Source: Internet
Author: User

To learn Java, you have to install the JDK (Java Development Kit Java Development Kit), configure the environment to learn Java, the following is a tutorial to download and install the JDK:
1.JDK Download Address:
Http://www.oracle.com/technetwork/java/javase/downloads/index.html

Click to open the link you should see the following image shows the interface:

2. Click on the arrow indicated in the above, the following interface will appear, at this time you need to according to your computer system for the corresponding version of the selection, in the selection and download before you need to receive the protocol, the specific interface as shown in the following image:

3. Double-click on the installation of JDK later (remember to follow the second picture to modify the installation path, do not install anything to the system disk ...) ):
(1) Double-click to install the interface as shown below:





4. After installation, you need to configure the environment variables, right key My Computer-Properties-Advanced system settings will see the following interface:

5. Click on the environment variable in the above diagram and start the configuration of the environment variable:
(1) Click on the New button under the system variable, the variable name Java_home (on behalf of your JDK installation path), the value corresponds to your JDK installation path.

(2) Continue to create a new CLASSPATH variable inside the system variable whose value is shown in the following figure:

Note here: There is a small dot at the front of the English state .... Many beginners fall into the hole when they configure the environment variable.
(3) in your system variable to find a variable name is the variable of path, you need to add a paragraph in its domain code as follows:

%java_home%\bin;%java_home%\jre\bin;

At this point you should append to your original range and remember to add a semicolon in the English state after the original domain.
Finally click OK, at this time the JDK environment variable configuration is completed.
6. Test your own configured environment variables are correct
(1) Windows+r key, enter cmd, enter the command line interface, as follows:

(2) Enter the Java-version command, you can see the following diagram prompts, you can look at your installed JDK version.

(3) The input Javac command can appear with the following prompts:

(4) The input Java command will appear as shown in the following figure

7. Write a piece of code to verify
(1) I created a new folder in E-disk called Javafile, in which there is a Java file, called Testjava.java, at this point, you need to note that your file name suffix must be. java
(2) You need to write the following code in your file:

public class testjava{public

    static void Main (string[] args) {
        System.out.println ("I am a  java new learner!") ;
    }
}

(3) Continue windows+r key into the DOS command line, you need to first enter the directory where you java files, and then use the Javac command to compile your Java files, and then use the Java command to parse the results of your JAVAC command compilation, It will look like this:

You must be aware of the directory in which the file is located, followed by the name of the Javac command file followed by the. java file suffix; Java suffixes can be used without writing.
When you execute the javac command without error prompts, the instructions are compiled and a. class file with the same name will be generated in your file directory.

If you have completed all of the above and the results are correct, then your JDK installation and environment configuration will be successful, and you can start your Java learning now.
JDK1.8 API Links:
http://docs.oracle.com/javase/8/docs/api/
JAVA Tutorials:
http://docs.oracle.com/ javase/tutorial/

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.