What is non static block in java
Answer Posted / raj_allinterview
Non static block is a block which is surounded by { and }
for ex :
{
//code goes here
}
The code within non static block is executed whenever a new
instance of that class is created.
It is instance block.
| Is This Answer Correct ? | 25 Yes | 2 No |
Post New Answer View All Answers
Explain enumeration in java?
How transient variable is different from volatile variable?
What does ide stand for?
Where is java located?
What is string :: npos?
What is r * in math?
What is a line separator in java?
Will the jvm load the package twice at runtime?
What is null data type?
What is string builder?
What is indexof?
Explain the features of java?
FOR EXAMPLE WE R HAVING TWO LIST ELEMENTS ..BOTH LISTS CONTAINS ID,NAME,PLACE ..I NEED TO COMPARE BOTH IDS IN TWO LISTS,IF ID'S R SAME MEANS WE HAVE ADD THE DETAILS(LIKE NAME,PLACE) TO MAP...HOW IS POSSIBLE ?CAN ANY ONE SUGGEST?
How use .contains in java?
Can private method static?