What happens when you attempt to compile and run the following code?
#include
#include
using namespace std;
class myClass : public exception
{
virtual const char* what() const throw()
{
return "My exception.";
}
} obj;
int main () {
try
{
throw obj;
}
catch (exception& e)
{
cout << e.what() << endl;
}
return 0;
}
Mariann
2 months agoAnnamae
16 days agoSoledad
28 days agoIsadora
1 months agoLenny
2 months agoAngella
2 months agoSharmaine
1 hours agoMyra
4 days agoFletcher
24 days agoMerrilee
1 months agoAlease
2 months agoRobt
2 months agoMelvin
1 months agoColby
2 months agoAmber
2 months agoRima
2 months agoCordelia
3 months ago