What is the difference between Static and final?
Answer / vetri
in variable,specifying final the value cant be changed
through
entire program.specifying static means the variable value
will persist between different method calls,automatic
initialization of static variable is zero.static and final
methods cant be overriden with non static or non final method.
but static and final methods can be overriden with static
and final methods in the subclass.
| Is This Answer Correct ? | 4 Yes | 4 No |
Difference between static methods, static variables, and static classes in Java.
What is a class component?
What is the difference between state-based unit testing and interaction-based unit testing?
How the elements are organized in GridBagLayout?
How do you sort a string in java?
What is the difference between member variables initialization and assignment in a constructor?
What is the implementation of destroy method in java. Is it native or java code?
Explain Stream Tokenizer?
What is pass by value?
What is use of super keyword?
What is the need to implement Serializable interface (with no methods) for objects which are to be serialized ? We can write our own functionality which writes objects to streams then why we need to implement and tell JVM that which objects can be serialized.
What is the use of hashmap in java?