Hello there. Ravi here with the java lesson. I hope that u installed jdk properly and configured it correctly. So no more further talks, let’s move on to the today’s lesson.
So today we are going to write simple java application. (not simple it is the simplest)
Anyway first step…..open notepad and type the following things in that..(sooo u are copying neeee…ok ok..copy it properly)
/*This is a simple java program.
Save this file as hello.java
*/
class hello
{
public static void main(String args[])
{
System.out.println("Ayubowan Elakiri");
}
}
Ok. I hope that u have typed it correctly. Then u have to save this file as hello.java.
How to do it?? Go to File menu > save as> and then u will get a familiar dialogue box.
Heeeey can u see a place for name u r document. For the name u have to type hello.java.
Hmmmmmmmm…where should u save it..save it in C:\. Ok finished.
Now go to command prompt. (run>cmd) then u will see something like this
then u have to change the directory to where u saved u r hello.java file.
so we have to move to c:\ (if u are in c:\ no problem)
to move to c:\. Type cd\ and hit ENTER.
ok nedaaaaaaaaaaaa!...now type javac hello.java and press ENTER.
Then u will notice that something is going on..no worries after sometime u will see the dir move to c:\ again.
ok.now u have compiled u r java source file. now u are going to run u r first application..before that set the classpath( i will explain abt these things in future lessons)to c:\
in command prompt type set classpath=c:\ and hit ENTER.
uuuuuuuhoooooooooooooooooooooooo......now we are going to run the application...heeee heeeeeeee...
ok..as u are back in c:\ in the command prompt. type java hello
AND HIT ENTER
soooooooooooooooo what u got!!!!!!!!!!!!!!!!!!!!!!!
if u followed the steps correctly u will get following result.
so. how u feel after running u r first java program..
he heeeee when i was doing my first java program i faced up to awful lot of problems...ketiyen kiwwoth JAVA epaaaaaaaaaaa unaaa...he heeee but nevertheless u learn by experience neeee....so if u face to any problems when doing this post u r problems here.....
bye and c yaaaaaaa..
ps-running the first program always gives u a great feeling.
So today we are going to write simple java application. (not simple it is the simplest)
Anyway first step…..open notepad and type the following things in that..(sooo u are copying neeee…ok ok..copy it properly)
/*This is a simple java program.
Save this file as hello.java
*/
class hello
{
public static void main(String args[])
{
System.out.println("Ayubowan Elakiri");
}
}
Ok. I hope that u have typed it correctly. Then u have to save this file as hello.java.
How to do it?? Go to File menu > save as> and then u will get a familiar dialogue box.
Heeeey can u see a place for name u r document. For the name u have to type hello.java.
Hmmmmmmmm…where should u save it..save it in C:\. Ok finished.
Now go to command prompt. (run>cmd) then u will see something like this
then u have to change the directory to where u saved u r hello.java file.
so we have to move to c:\ (if u are in c:\ no problem)
to move to c:\. Type cd\ and hit ENTER.
ok nedaaaaaaaaaaaa!...now type javac hello.java and press ENTER.
Then u will notice that something is going on..no worries after sometime u will see the dir move to c:\ again.
ok.now u have compiled u r java source file. now u are going to run u r first application..before that set the classpath( i will explain abt these things in future lessons)to c:\
in command prompt type set classpath=c:\ and hit ENTER.
uuuuuuuhoooooooooooooooooooooooo......now we are going to run the application...heeee heeeeeeee...
ok..as u are back in c:\ in the command prompt. type java hello
AND HIT ENTER
soooooooooooooooo what u got!!!!!!!!!!!!!!!!!!!!!!!
if u followed the steps correctly u will get following result.
so. how u feel after running u r first java program..
he heeeee when i was doing my first java program i faced up to awful lot of problems...ketiyen kiwwoth JAVA epaaaaaaaaaaa unaaa...he heeee but nevertheless u learn by experience neeee....so if u face to any problems when doing this post u r problems here.....
bye and c yaaaaaaa..
ps-running the first program always gives u a great feeling.
