OCA Java SE 8 Exception - OCA Mock Question Exception 15








Question

Which of the following are true? (Choose all that apply)

  1. Checked exceptions are allowed to be handled or declared.
  2. Checked exceptions are required to be handled or declared.
  3. Errors are allowed to be handled or declared.
  4. Errors are required to be handled or declared.
  5. Runtime exceptions are allowed to be handled or declared.
  6. Runtime exceptions are required to be handled or declared.




Answer



A, B, C, E.

Note

Checked exceptions are required to be handled or declared.

Runtime exceptions are allowed to be handled or declared but not required.

Errors are allowed to be handled or declared, but it is not a good practice to handle Error.