posted 18 years ago
Hi Swarupa,
"You are compiling file Name.java and java compiler gerates the Test.class and Name.class files so when u run the java program using Name class it shows NosuchMethodError because it doesnot have main method and u r trying on Name class ,Try to run program using java Test"
Are you sure? If we compile file Name.java and java compiler generates the
"Test.class and Name.class" for the above code.
According to me it generates only one class file with name Test.class.
Correct me if i am wrong
Thanks a lot
Thanks a lot<br />Learn from yesterday, live for today, hope for tomorrow. The important thing is to not stop questioning