Predict the output for the following program

int main() {
try  {
throw 'a';
}
catch (int x)  {
cout << "Caught a";
}
return 0;
}

Caught a
No output
Compile time error - No valid exception handler
Terminate called after throwing an instance of 'char'
Verified Answer
Correct Option - d

To get all Infosys Certified CPP Programmer Exam questions Join Telegram Group https://rebrand.ly/lex-telegram-236dee

Telegram