what is the difference between static block and static
method
Answer Posted / hathwar
static block will execute when ever execution starts, it
means this block executes first of all, where as static
block have to call seperately and also it can call with out
object instance.
| Is This Answer Correct ? | 41 Yes | 51 No |
Post New Answer View All Answers
Implement a stack with push (), pop() and min() in O(1) time.
What is difference between array and arraylist in java?
Can we instantiate interface in java?
What is the difference between JVM and JRE?
What are nested classes in java?
What do you mean by default constructor in java?
What is void class in java?
What is derived datatype?
what is singleton class in java?
Explain the difference between throw and throws in java?
How do you clear a method in java?
Is space a char?
What is a subsequence of a string?
Where are the card layouts used?
what invokes a threads run() method? : Java thread