CBSE Class 12 Computer Science Exception Handling In Java Online Test Set D

Page 1 of 20

Question 1

Question

Which of the following is true about try/catch blocks in Java ? (I) All try/catch blocks must have a finally block. (II) A try/catch block is limited to two or less catch blocks. (III) Barring the Java virtual machine from exiting, the finally block will always be executed.

Answer
(I) and (III)
(I) and (II)
(III) only
(I) only