Multiple Choice Question

Quiz Guidelines

 

QID: 
542
Question: 

You have a method that currently does not handle any exception thrown from the code contained in its method body. You are now changing this method to call another method that throws IO Exception.

What changes, independent of each other, can you make to your method so that it will compile?

Select 2 options

A. Set the exception to null and don't rethrow it.
B. Declare IO Exception in the throws clause of your method.
C. Wrap the call to another method within a try-catch block that catches RuntimeException.
D. Wrap the call to another method within a try-catch block that catches Exception.

Q&A Set: