what is the difference between static block and static
method
Answer Posted / sukhvider
static block executes whenever the class loaded in the Java virtual machine that means object is before going to main Method.
| Is This Answer Correct ? | 1 Yes | 4 No |
Post New Answer View All Answers
What is a stringbuffer?
How do you override a variable in java?
why doesn't java run on all platforms?
what do you mean by stream pipelining in java 8? Explain
In java, how we can disallow serialization of variables?
Is void a data type in java?
What is the different types of functions?
Difference between throw and throws?
How many types of interfaces are there?
Why does java have two ways to create child threads? Which way is better?
What is final keyword?
Can we write any code after throw statement?
What does the exclamation mark mean in java?
What is this () in java?
extending thread class or implementing runnable interface. Which is better? : Java thread