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


Please Help Members By Posting Answers For Below Questions

What are memory tables?

849


What is ternary operator in java?

829


Are arrays primitive data types?

860


Can you give names of Container classes?

2054


What is a double?

832


How do you sort an array in java?

792


How many bytes is string in java?

903


What is the purpose of void class?

815


What is main difference between variable and constant?

787


What is a copy constructor in java?

829


How do you clear a list in java?

823


What are static methods?

818


Variable of the boolean type is automatically initialized as?

790


What is a boolean output?

733


What is java in detail?

834