Current location - Recipe Complete Network - Food world - How to write JAVA programs and how to create new programs in eclipse?
How to write JAVA programs and how to create new programs in eclipse?
Step 1: Start Eclipse. When you start the software for the first time, you will be prompted to select a workspace. You can create a new folder on your hard disk as a workspace, which will store all the source codes you have written.

Step 2: Create a new simple Java project. Click file-> New-> Project-> Java project.

Step 3: Especially fill in the project name and source folder. Typically, the default src is the root folder.

Step 4: Create a new package in the project. It is worth noting that package names and project names generally start with lowercase, while Java class names start with uppercase. Right-click src and click New-> Bag-> Fill in the package name.

Step 5: Create a new Java class in the package. There can be multiple Java classes in a package, and Java classes are the areas where we write code. Right-click the newly created package in the previous step and select new-& gt;; Class, fill in the class name.