we have a 100 classes at that time which class we have to
write main method? pls help me
Answers were Sorted based on User's Feedback
Answer / ankit sangal
we should write the main method in that class from where we want to start the compilation.
Is This Answer Correct ? | 16 Yes | 1 No |
Answer / pravallika
we can write main method in any class is possible.
Is This Answer Correct ? | 9 Yes | 1 No |
Hey All,
I Think if we have 100 class we write main method wihin
any class just we should mention class name in mainifest
file before calling.mainfest main work is tp provide main
class name to jvm.
Is This Answer Correct ? | 2 Yes | 0 No |
Answer / pravallika
But compile time point of view main method is not required.so we can write main method in any one class is possible.
Is This Answer Correct ? | 1 Yes | 1 No |
Answer / john kennedy
The class which has the connection or relationship with all
other classes can be main class.
Is This Answer Correct ? | 0 Yes | 0 No |
I want to run a simple hello world java (HelloWorld.java) program using a batch file. How can i run it and how to construct a batch file.
Howmany number of objects we can store in an ArrayList. Is there any limit?
i need example for java abstraction. where we use abstraction and why we need abstraction.
Marker interface means , interface which has no methods.Then what is the necessity of its usage.I read "it tells the compiler that it should be treated differently ". "It is used to store state of an object". But still am not clear.Please explain clearly.
What are wrapped classes?
What is the difference between constructor and method?
What are default methods ?
What is java thread dump, how can we get java thread dump of a program?
Can you override a private or static method in java?
Can we have a abstract class withought any method? What is a purspose of this?
How do you convert bytes to character in java?
What is a boolean in java?