Question:What is the purpose of the catch block in the following code?
try { 
    // Code that might throw exceptions of different types 
}
catch { 
    // Code goes here 
}
 

A Only errors of type std::unexpected are caught here. 

B Other code exceptions are caught. 

C This catch block must be the first one in a series of catch blocks that may or may not be followed. 

D This catch block can be the last one in a series of catch blocks to handle any exception which is not handled by the preceding catch blocks, each of which handles an exception of a particular type. 

E No errors are caught in this try block (they are all passed to the next closest catch). 

F None of these. 

+ Answer
+ Report
Total Preview: 926

Copyright © 2024. Powered by Intellect Software Ltd