Java Programming For Beginners: Step By Step Lesson #2 || Creating Our First Project And Package (By @kaffy22 - The Code Girl)
What Will I Learn?
- You will learn How to intract with Eclipse IDE
- You will learn how to create your first Java Project
- You will learn how to create package for your Projects.
Requirements
- Computer system
- JDK must be installed
- Eclipse IDE
Difficulty
- Basic
Welcome back, budding programmers. Like I said earlier, programming is not so hard as many people make it seems. You just have to be focused and committed and in no time, you're gonna make a great programmer.
Today, we are going to write our very first java program. I've listed above all you need and if you followed my post yesterday, then you'll understand where we are.
A quick recap of the previous lesson here
Let's start guys!
Open your Eclipse IDE
Let's launch our Eclipse IDE app to get started. Don't get scared, I'll be showing you every step with screenshots. That's the purpose of this tutorial - it's meant to guide you from the very beginning to the end. Let's go.
That's how our Eclipse IDE looks.
Creating Our Java Project
Creating our Java project is as simple as listed below .
- Click on File at the top menu and select New
- From New to Java Project
A new small window appear. Input your project name and click on Finish and we are all set.
Now, I'll like us to be storing each project we're gonna be working in one single package. A package simply houses projects. That's it.
Creating a package for our projects
To create a package, the steps are as simple as listed below .
- Right-click on the project we just created. And choose a new Package. Screenshot below.
On the new window that appears, input your desired name for the project. Here I named my package FirstPrograms. take note of something, You're not permitted to leave space in your project name. Just write all the words together as one. You can separate each word from the other using Capital letter to begin each word. Click on Finish and we all set.
See our new project package below.
You can create as many packages as you wish. You can also choose to be creating new package for every Java Application you're writing. However, I will like us to be saving our works inside this one package.
Creating Project Class
If you've reading some books about Java Programming before, you already know what a class means in Java. Class houses objects. Now let's create our first class.
- Follow the same method you used in creating a package but this time, choose class instead.
Insert the Class name with the same rules used when naming the package. Tick the box for public static void
Behold! We are set to go! Simple, right? Yes!
This is where we are going to stop for now, we'll continue in the next class. Stay with this blog.
Like I do tell you guys, programming is not hard, programming is not easy, your approach determines which of its side programming shows to you - easy or hard
Be sure to leave a comment and upvote. A resteem is also appreciated.
Curriculum
Posted on Utopian.io - Rewarding Open Source Contributors
Your contribution cannot be approved because it does not follow the Utopian Rules.
Hi, these are the reasons your contribution was rejected
I recommend you read the rules before contributing again in the future.
You can contact us on Discord.
[utopian-moderator]