Question: Which of the following statements is true? Select the one correct answer. (a) If an exception is thrown during execution of the finalize() method of

Which of the following statements is true?

Select the one correct answer.

(a) If an exception is thrown during execution of the finalize() method of an eligible object, the exception is ignored and the object is destroyed.

(b) All objects have a finalize() method.

(c) Objects can be destroyed by explicitly calling the finalize() method.

(d) The finalize() method can be declared with any accessibility.

(e) The compiler will fail to compile code that defines an overriding finalize() method that does not explicitly call the overridden finalize() method from the superclass.

Step by Step Solution

3.51 Rating (164 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

b The Object class defines a protected finalize method All classes inherit from Object th... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Java Programming 8th Questions!