wat is final...?
wat is finally...?
wat is finalize....?
difference between " final and finally and finalize "...?

Answer Posted / chaithanya

Final:It is a keyword,constant like c/C++.suppose if we declare a=1,we cannot change that value over the programme.we cannot declare a++.
Finally():It is default block in exception handling.
Finalize():if an object holds non java resources,it must be releases resources before object is destroyed.called garbage collector.it runs periodically.we don't know when gc runs
so the programmer write in manually in finalise method invoked the gc before object is destroyed

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is bufferedwriter?

542


Can we define private and protected modifiers for variables in interfaces?

588


What is parameter example?

550


Why can't you declare a class as protected?

604


What does \ mean in regex?

626






What is meant by method?

581


What is difference between arraylist and list in java?

588


What is not object oriented programming?

511


Explain the transient field modifier?

569


What is JFC?

715


Does garbage collection occur in permanent generation space in jvm?

611


Explain heap sort?

705


what are three ways in which a thread can enter the waiting state? Or what are different ways in which a thread can enter the waiting state? : Java thread

527


Is vector synchronized in java?

559


What is backdrop?

601