What is the final keyword?
Answer / Najir Husen
The final keyword in Java is used to restrict a method or a variable from being overridden by subclasses, or it can also be used to declare that an object of a class cannot be instantiated. For methods, once they are declared as final, they cannot be overridden by any subclass, and for variables, they can only be assigned a value once at the time of declaration.
| Is This Answer Correct ? | 0 Yes | 0 No |
Can I overload to string method
How arrays are stored in memory in java?
How do you compare two objects?
What are the differences between include directive and include action?
What environment variables are required to be set on a machine in order to run Java programs?
how to run ecllipse with jettyserver for windows environment using batch file
Why we use methods in java?
What is the use of java?
What are the benefits of immutable objects?
What is a stream? what are the different types and classes of Streams?
Why set do not allow duplicates in java?
What about method local inner classes or local inner classes in java?