Alert icon
We're changing our privacy policy. This stuff matters.  Learn more  Dismiss

Wil's Java Lesson One

Loading...

Sign in or sign up now!
3,251
Loading...
Alert icon
Sign in or sign up now!
Alert icon

Uploaded by on Dec 28, 2007

This is my very first java lesson. Java is a programming language that was created in the 90's that is very powerful and very useful. These lessons are aimed at people who like computers and understand at lease what a programming language is. I will have more java tutorials, as well as other programming language tutorials, like QBasic and HTML, in the future.

Note: If you ever want to learn java, I recommend "Beginning Programming with Java for Dummies" by Barry Burd, and when you feel like being advanced, "Java all in one desk reference" by Doug Lowe.

Java Explanation:

Here is an explanation of that jumble of java code: "class WilsJavaLessonOne" defines a java class named 'WilsJavaLessonOne', and everything between the { and the } is the body of the class. Remember, these are basic lessons. I'm not going to describe everything to you. But a class is pretty much the main unit of java code. Everything is in a class.

The "public static void main(String[] args)" is a little hard to explain. Just know that at the beginning of the first java class in the program, you have to type that. It is the beginning of a method, which is pretty much a step down from the main unit of classes. Classes are made up of methods. The 'main' keyword marks the spot where the computer starts to process your code. Everything between the { and the } is the body of the method.

Now for "System.out.println("Hello World!");" Methods are made up of statements. Statements usually end in semicolons. When you code java, you are actually using other people's code. But to understand that, you have to know what the java API is. It is the main library of java code. It is organized like this: Classes have objects which have methods. For example, "System" is a java class. "out" is an object of "System". "println" is a method of the "out" object. So "System.out.println("Hello World!");" displays "Hello World!" on the computer screen. I know, it's hard to understand. But just look at the code and just memorize the layout and the statements.

Category:

Education

Tags:

License:

Standard YouTube License

Link to this comment:

Share to:

Top Comments

  • you don't explain that how to compile and get out put............

  • or at least say stuff instead of type it

see all

All Comments (6)

Sign In or Sign Up now to post a comment!
  • @drinu93 download a java IDE such as JCreator or eclipse (i perfer JCreator) and it should have every thing you need.

  • u suckkkkkkkkkkhhhh

  • actually i want to learn java.. i dont know how to complile.. how do hell would i know how to compile if i want to learn :S

  • I assumed that if you wanted to learn Java, you would at least know how to compile and run a program.

Loading...
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more