Answer the following questions true (T) or false (F)

1. The context in which an exception is handled (or managed) is the throw block.

2. Statements that cause an exception must be part of a try block.

1. False
Explanation: The context in which an exception is handled (or managed) is the catch block.
2. False
Explanation: Statements that cause an exception to be thrown need not be in a try block. However, if the exception is to be caught, the throw statement must be directly in the try block or there must be a call to a function that has the throw statement in the function in the try block.

Computer Science & Information Technology

You might also like to view...

What can you conclude when you use Six Sigma and get a Four Sigma rating. Which rating would be applicable?

a. semi-perfect b. perfect c. productive d. needs work

Computer Science & Information Technology

Code review and testing should identify bad programming patterns, security misconfigurations, functional bugs, and logic flaws

Indicate whether the statement is true or false.

Computer Science & Information Technology