Which function is used to perform some action when the object is to be destroyed?
(a) finalize()
(b) delete()
(c) main()
(d) none of the mentioned
I had been asked this question in an online quiz.
My doubt stems from Constructors & Garbage Collection in division Classes and Methods of Java