Java

Moderators: zibadian
Number of threads: 7818
Number of posts: 18218

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
Java tutorial Posted by javalovar92146 on 12 Jan 2013 at 12:00 PM
First of all, I am new to programmers heaven. Second, Java is an oo programming language. OO means object-oriented. Object oriented is when, in a programming language, objects communicate to one another to perform tasks, and/or call methods.

Heres the structure for a .java source file:

SOURCE
CLASS
METHODS
STATEMENTS

A source is he whole .java file.
A Class is a 'new part' of the source code
A method, aka a void, is a block of code that holds statements.
A statement is a command.

Here's an example code

public class myFirstProgram {
public static void main(String[] args) {
System.out.pintln("Hello!");
}
}


EVERY STATEMENT MUST HAVE A SEMICOLON AFTER IT!

Keep an eye out for my next tutorial!



 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.