KidsLovePC Contact Us
  Home   PHP  Graphics ASP  JavaScript   J2EE  HTML  JAVA   Swing   Webtip  Forums  Lyric  Free sheet music  Ringtones

 First cup of JAVA

There are 3 steps to speak JAVA:

1. Type code

2. Compile code

3. Run code.

First step: type the following code to Wordpad or any text editor you are familiar with. (cann't find your WordPad? go to Start ->All programs->Accessories? Got it? Still not, ask your mom/ Daddy help you)

class hello 
{ 
   public static void main(String[] args)
  {
   System.out.println("Hello! It is me, JAVA boy!");
  }
}

Be cageful! Type the above code exactly as it is. I am very strict with my language. I am case sensitive. class,Class means different things to me!

Finished typing? All right! Save it as a file named hello.java. .java is my family name( those computer guru calls it extension name. Well, what ever...) You may ask could I save it as bulabula.java? NO!! you have to save it as hello.java. hello is the file's first name and it is the class's name too( see the first line in the code). The file's first name MUST match its class name. MUST!

Second Step: compile hello.java. ( I assume you installed JDK5.0. Please see Appendix for detail installation. If you are a parent, do it for your kids. If you are a kid, take an adventure and install it by yourself. It is very easy to install.) Now, open a command prompt. (Start->All programs->Accessories->Command prompt).

Type: javac hello.java

If JDK was installed in a right way, you won't see any error.

Third Step: run hello program. Still in that command prompt,

type: java hello

You should see: Hello! It is me, JAVA boy!

Congratulations! You are speaking JAVA!

 

 

Try & Catch Exceptions
 
How to install JDK
Homework Solutions
 
JAVA JTable
JAVA JTree
JAVA JComboBox
JAVA JTabbedPane
Java JList
JAVA JToolTip
Javascript
WebTip
Forums
Best JAVA books
Head First JAVA, Second Editon

Effective Java Programming Language Guide

Professional Java, JDK 5 Edition

Ivor Horton's Beginning Java 2, JDK 5 Edition

 

 

 

Best books about JAVA programming from Amazon
Professional Java, JDK 5 Edition (Paperback Simply Java Programming: An Application-Driven Tutorial Approach (Paperback) Effective Java Programming Language Guide (Paperback) Head First Java, 2nd Edition (Paperback) Java : An Introduction to Problem Solving and Programming (4th Edition)

 

Printer Inkjet A Z lyricsLearn ChineseHome|PHP|Swing|HTML|JavaScript|ASP|JAVA|Forum|WebTip|Contact Us
Copyright © kidslovepc.com All rights reserved(new). Privacy|Copyright
designed by info@kidslovepc.com

Please help us cover the web site maintenance fee.
barcode scanner Thermal Printer credit card machine bar code printer