Home / MCQ Bank / Computer
Computer Plus Plus Miscellaneous

What will be the output of the following C++ code? #include <iostream> using namespace std; int main () { try { throw 20; } catch (int e) { cout << "An exception occurred " << e << endl; } return 0; }

Select the best option to verify your answer:
Show Correct Answer
Correct Answer: Option D • An exception occurred 20

Related Computer Questions

What will be the output of the following Python code? def writer(): title = 'Sir' name = (lambda x:title + ' ' + x) return name who = writer() who('Arthur') getCurrentPosition does not take the argument? Determine Output: void main() { int i=-1, j=-1, k=0, l=2, m; m = i++ && j++ && k++ || l++; printf("%d %d %d %d %d", i, j, k, l, m); } The length of a word in computer is measured in: Which of the following are ways to benchmark code?