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 a lightweight component?
what is use of functional interface in java 8?
What are triggers in DB? Explain their types. How do they work?
How do you end a program?
Why parsing is done?
What do you mean by JVM?
what are three ways in which a thread can enter the waiting state? : Java thread
What environment variables do I need to set on my machine in order to be able to run java programs?
How many techniques can be employed to create a string object?
How many unicode characters are there?
How list contains works in java?
What is a flag value?
Which variables are stored in stack?
How to calculate the length of a singly linked list in java?
What is the purpose of javac exe?