what is the difference between statis block and static
variable
Answer Posted / suresh.m
staticblock,static variables,static method are executed
before creating an object to be created to class.i think
there is no difference between them.
| Is This Answer Correct ? | 2 Yes | 11 No |
Post New Answer View All Answers
In case of inheritance what is the execution order of constructor and destructor?
Which is better list or arraylist in java?
How do you add an element to a hashset in java?
What is the difference between break and continue statements?
enlist some features of jdk.
Can a class be private in java?
What is string subsequence method?
What is jar?
What is early binding and late binding in java?
What is an empty string in css?
Is a char always 1 byte?
Can we have return statement in finally clause? What will happen?
How objects of a class are created if no constructor is defined in the class?
What is the exception hierarchy in java?
Is 0 true or is 1 true?