What is non static block in java
Answer Posted / mohan
In between {....}whatever u can write that consider as
Instance block or Non static block.
Ex:
class hai{
//Instance block
{
System.out.println("hi i'm Instance block....");
}
//Static block
static{
System.out.println("hi i'm Static block....");
}
}
| Is This Answer Correct ? | 8 Yes | 0 No |
Post New Answer View All Answers
What is the different types of functions?
What is the difference between form & report?
What is protected in java?
Define how destructors are defined in java?
Java.util.regex consists of which classes?
What is api in java?
Is it possible for yielded thread to get chance for its execution again ?
Why string is called as immutable?
Explain about public and private access specifiers?
What is a generic code?
how we can create packages in java?
What is the final access modifier in java?
What is an interface in java?
What are the methods used to implement for the key object in the hash map?
State some situations where exceptions may arise in java?