what is the difference between statis block and static
variable

Answer Posted / narasimha

i wolud like a new point to the above answer.
first the static varibles are inistalized then the static
bloks are executed.

Is This Answer Correct ?    3 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What’s the difference between the methods sleep() and wait()?

548


Write a program to calculate factorial in java?

595


Which one of the following suits the description of a string better: derived or primitive?

519


Define nashorn in java8.

570


What is a concrete classes? Is Java object class is concrete class?

522






What is navigable map in java?

529


What is an inner class in java?

535


What is string in java?

570


Which is bigger float or double java?

534


what is mutual exclusion? How can you take care of mutual exclusion using java threads? : Java thread

691


What are the actions that can occur when a thread enters blocked state?

589


What type of variable is error flag?

599


What is break and continue statement?

623


How do you add an element to an arraylist in java?

494


How can we make sure main() is the last thread to finish in java program?

679