Instructions: Before we begin your going to need a program to start programming with go to eclipse.org you will be presented with a bunch of downloads, but should download you one that is presented in this picture
and you will know which is the right one to download. Assuming you have done the installation process we can now begin !
Part 1.
Let's begin: Before we begin, you should have Eclipse open and start a New project
Example
Then we're going to need classes which i will explain later
Example
When creating classes, we allways need 1 main class so the project knows where to begin
Example
Once were done we should automatically have what looks like this
Example
Part 2.
Lesson: Here are some things you should know before you continue onto our exercise!
Definitions: Variable - is a facility for storing data.
Class - Java is class-based programming, which refers to the style of object-oriented programming in which inheritance is achieved by defining classes of objects.
Primitive data types:
int - aka Integer, you've probably heard if you have ever been in a Math class but in programming it's a little bit different. It can be a negative, neutral or positive number.
String - Is basically a string of words or letters example: "Hello world!"
Boolean - Your probably thinking "Wow boolean thats a weird word". It really just has one of two values; true or false.
Statement structure:
A class is made up of a bunch of different statement, the structure for creating a statement goes like this. (data type) (variable name) = (data value); Your probably woundering what the ";" semicolon is doing there, in Java we allways end our statements with semicolon.
Resource Program Here
0 comments:
Post a Comment