Explain final, finalize() and finally?

Answer Posted / guest

we can declare final for class ,method,varible.
final varibles are unchangeble.
final classes are not subclassed.
final methods are not overriden.
finilize()
to clean up memory resourses for object using finilize().
finally block is executed if exception thrown or not.

Is This Answer Correct ?    100 Yes 9 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is palindrome in java?

562


Explain the importance of finally block in java?

569


How do you sort a list in java?

582


Which collection is sorted in java?

552


placement papaers of spring computing technology

1026






What are the two ways in which thread can be created?

598


What is the use of predicate in java 8?

494


What is the difference between preemptive scheduling and time slicing in java programming?

536


Why to use nested classes in java? (Or) what is the purpose of nested class in java?

526


How do you use compareto in java?

561


What is the class in java?

563


Can keyword be used as identifier?

547


Can we have multiple catch block for a try block?

588


How do you create immutable object in java?

539


Is string thread safe in java?

581