Use eclipse to develop Java

Source: Internet
Author: User

Today, Shimei said she would start Java, so she went to the eclipse official website.

Go to the download topic, which contains the classic version. Click to download.

It is a zip file. After decompression, double-click the file and find that the prompt is missing JRE or JDK, So download JRE (after all, JRE is small)

Install JRE under Eclipse/JRE, and double-click eclipse to run it.

Perform the following steps to test helloworld and verify that Java command line development can be performed.

Step 1: Create a Java Project

Select "file → new → project...", select "Java Project", and click "Next" to open the "New Java project" Wizard. Enter "helloworld" in "Project Name". If no other settings are required, click "finish" on the left.

Step 2: Create a helloworldapp class

Select "file → new → class", enter "helloworldapp" in the Name box in the "New Java class" wizard, and in "public static void main (string [] ARGs).

The wizard prompts you that the package is not required because the project is simple. Finally, press the "finish" button. At this time, you will find that the Hello world!ProgramFrameworkCodeAutomatically generated. This is the code generation feature of eclipse (see figure 3 ).

Step 3: Add a print statement

The output "Hello World!" is missing in comparison to the Code in the previous connection !" Statement:

System. Out. println ("Hello world! ");

Related Article

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.