hi gyz, i've got my first Assignment of java. first i do coding plz take a look. : /* The HelloWorldApp class
implements an application that simply
displays "Hello World!" to the standard
output. */
public class HelloWorldApp{

public static void main(string[]args){

//Display the string.No global main System.out.println("Hello World!");
}
}

After this when i've try to compile the it like this : first i dwonload jdk 5.0 and i've save file the name of "HelloWorldApp.java" then i've open the comand prompet and wrote javac HelloWorldApp.java there comes an error like 1 error . where i do mistake plz guide me.
thanks in Advance

Post the error message here..
and

string[]args)

String is a class . it should be capital.

public static void main(String[] args)

when i'd compile by javac HelloWorldApp.java the error becomes :

error: cannot read: HelloWorldApp.java 1Error

well, that just means the compiler either can't find the source file or you've got the file permissions set for it to be not readable for the compiler.

If you are compiling from command prompt , make sure that you are in the same directory where your source file is present.

you right sir but,
right now,I've copy and paste that file into bin folder of jdk.
then i've copy the path of bin folder and wrote in comand prompt :

cd path of bin folder

then hit 'enter' its done and after that when i try to compile again same Error becomes again.
one thing when i ignore that error and do the next step wrote java HelloWorldApp.java and hit the 'enter' as a result my coded notepad file names HElloWApp.java opens.
i think i should try to listen the basic lecture again.

This article has been dead for over six months. Start a new discussion instead.