jay nair

Greenhorn
+ Follow
since Sep 13, 2005
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by jay nair

thanks , it works

I have to personally visit one of the Centres and ask them to book.
Hope this would be helpful for people registering in india
can you please tell the procedure to book dates online for SCJP ?

i tried booking from prometric website where it asks me to call this number
Please call 0124-4147760, Monday - Friday, 9:00 to 17:30 GMT +05:30 to schedule your appointment.


and this number does not work !!!

can some one help me?
Hi,

I have a SCJP 5 voucher 310-055 for sale.Willing to sell for 7000rs. ( considering the fact that its 200$ you still save 1000 rs).

Validity : 31st December

Only people from Pune may contact.

Reply here and we can carry it forward.

Thanks.
Jay

[ September 03, 2007: Message edited by: jay nair ]
[ September 03, 2007: Message edited by: jay nair ]
16 years ago
thanks marc , understood,... this thread also helped ,
17 years ago
So when you say this.ounces = ounces , it acatully means that private int ounces = int ounces ( declared in the arg of the contructor) ?
17 years ago





are'nt we supposed to declare another variable " ounces " inside the Constructor ?? , n if its the " private int ounces " then is it not supposed to be declared before this Constructor ???


am i missing something too obvious ? help will be appreciated , thanks


EDIT by mw: Put long code comment inside /* ... */ tags with line breaks to avoid a really long line that won't break within code tags.
[ April 22, 2006: Message edited by: marc weber ]
17 years ago
thanks a lot...
17 years ago

the above code just works fine ,
i wanted to know how " new TestServer().logIn();" works?
Is this line instantiating an object ( since its using " new" )
and if yes why is it not assigned to a variable of type TestServer?
17 years ago
thanks ernest ,
that makes sense , i guess i was seeing it in a complex way ....


thanks again ,
17 years ago
thanks ernest ,

i guess i was not descriptive about my problem....

well in the stack program , there is one public class , so according to rule the name of the file must be the name of that class , now if i do that it compiles fine but since the class in which the main method is there has the name nstack so wen i try to Run the program it gives me error saying it did not find any MAIN method ,

so my question is , i s there anyway this program will run ... or the only possible way is to make another file and put the public class ( stack class) in that file and name the file as stack.java ....

hope i was clear ,
thanks for ur reply ,
would really appreciate further clarifications ,
17 years ago
I am confused about file names , in the above code , if i keep the class name as nstack.java , the compiler says that class stack is public should be declared in a file name called stack.java ,



wat i meant was if i keep the FILE NAME as nstack.java not class name ...

sorry
17 years ago





I am confused about file names , in the above code , if i keep the class name as nstack.java , the compiler says that class stack is public should be declared in a file name called stack.java ,

now if i give the file name as stack.java then it compiles just fine but but when i try 2 run it it gives error " Exception in thread " man" java.langNoSuchMethodError: main


also i wanted to know what does this statement mean ...

* Files with no public classes have no naming restrictions.

if the above is true then



will the above code work if the File name is bool.java ???( i have noticed that when i compile it it gives out bool1.class which is normal , now if thats the case isnt the statemnet ( * files with no public classes have no naming restrictions) contradicted ?


Help will be appreciated ...
thanks in advance
17 years ago

Originally posted by sapna manga:
thanks.
i removed .exe files from my class path . now javac is working . i am able to compile .java and no errors.
but when i say c:\> java helloworld it is giving error"Exception in thread "main" java.lang.NoClassDefFoundError: helloworld/class"

How can i get rid of it?

--sapna




if u are in C:\ then you have to make sure the helloworld.java file is there in c:> itslef else it will give this error ... u hv to be in folder in which u have the .java file in order to compile and run it ....
17 years ago