OOPS
August 29, 2024OOPS
August 29, 2024OOPS
|
Question 132
|
Additional information sent when an exception is thrown may be placed in___
|
Additional information sent when an exception is thrown may be placed in___
|
|
|
The function that caused the error
|
|
|
The catch block
|
|
|
An object of the exception class
|
Question 132 Explanation:
→ A catch block is where you handle the exceptions, this block must follow the try block.
→ A single try block can have several catch blocks associated with it. You can catch different exceptions in different catch blocks.
→ When an exception occurs in try block, the corresponding catch block that handles that particular exception executes
→ A single try block can have several catch blocks associated with it. You can catch different exceptions in different catch blocks.
→ When an exception occurs in try block, the corresponding catch block that handles that particular exception executes
Correct Answer: C
Question 132 Explanation:
→ A catch block is where you handle the exceptions, this block must follow the try block.
→ A single try block can have several catch blocks associated with it. You can catch different exceptions in different catch blocks.
→ When an exception occurs in try block, the corresponding catch block that handles that particular exception executes
→ A single try block can have several catch blocks associated with it. You can catch different exceptions in different catch blocks.
→ When an exception occurs in try block, the corresponding catch block that handles that particular exception executes
