wat is final...?
wat is finally...?
wat is finalize....?
difference between " final and finally and finalize "...?
Answer Posted / mmkrish
final --> is a keyword. It will be used for variables,
methods and classes also.
final variables --> Cannot change their value.
final Methods --> Cannot override or overload
final Class --> it can never be subclassed.
finally --> is a block used in exception handling. Genrally
used along with try.catch blocks... though try or catch
block executes...finally block should execute at last.
Means, if we have add finally block, it will call though
there is an exeption occurs.
finalize() --> It is a method. This will be used in garbage
collection of java. It will clear all the unused
resources...Cannot Override. It is a protected method.
| Is This Answer Correct ? | 23 Yes | 0 No |
Post New Answer View All Answers
What does this () mean in java?
How are observer and observable used in java programming?
What is the difference between jvm and jre? What is an interface?
What is function and its uses?
Why is stringbuffer called mutable?
Can java object be locked down for exclusive use by a given thread?
Why java is used everywhere?
Write a function for palindrome and factorial and explain?
What is nested interface?
Where local and global variables are stored?
What is the use of list in java?
What is java and their uses?
What is the purpose of the finally clause of a try-catch-finally statement in java programming?
What is a pattern what is an anti pattern?
What are the Main functions of Java?