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
Why is a string immutable?
Does constructor return any value?
How can you read an integer value from the keyword when the application is runtime in java? example?
What is pre increment and post increment in java?
What is difference between final and finally in java?
What is string builder in java?
Can you sort a string in java?
Does java allow default arguments?
What is the difference between Java Program Constructor and Java Program Method, What is the purpose of Java Program constructor Please Explain it Breafily?
Is string is a keyword in java?
How many types of string data types are there?
What is jagged array in java?
What is ctrl m character?
What is the purpose of abstract class?
What is meant by stack and queue?