Q260
What will be the output of the following C++ code? #include #include using namespace std; class myexception: public exception virtual const char* what() const throw() return "exception arised"; myex; int main () try throw myex; catch (exception& e) cout << e.what() << endl; return 0;
A.
exception arised
AnswerB.
error
C.
exception
D.
runtime error
Answer: Option A
Solution
Answer: Option A
No explanation is given for this question Let's Discuss on Board