1.

What is the output of this program?
#include <iostream>
using namespace std;
void Example() throw()
{
cout << "In empty()" << endl;
}
void WithTypeFunction() throw(int)
{
cout << "Will throw an int" << endl;
throw(1);
}
int main()
{
try
{
Example();
WithTypeFunction();
}
catch (int)
{
cout << "Caught an int" << endl;
}
}

A. Caught an int
B. In empty()
C. Will throw an int
D. All of above
E. None of these
Answer» E. None of these


Discussion

No Comment Found

Related MCQs