Explain how an exception handler is defined and invoked in a Program.



Explain how an exception handler is defined and invoked in a Program...

Answer / Rahul Kumar Singh

An exception handler is defined using try, catch, and throw keywords. A try block contains the code that may throw exceptions. One or more catch blocks follow the try block and handle the exceptions of specific types. The throw keyword is used to generate an exception.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C++ General Interview Questions

Which recursive sorting technique always makes recursive calls to sort subarrays that are about half size of the original array?

1 Answers  


Is there any problem with the following: char *a=NULL; char& p = *a;?

1 Answers  


Write a program to show polymorphism in C++?

1 Answers   Impetus, Verifone,


Describe the advantages of operator overloading?

1 Answers  


Can a list of string be stored within a two dimensional array?

1 Answers  


Why do we use structure in c++?

1 Answers  


How to give an alternate name to a namespace?

1 Answers  


What is the use of bit fields in structure declaration?

1 Answers  


What is the role of C++ shorthand's?

1 Answers   TCS,


Can we make copy constructor private in c++?

1 Answers  


what are function pointers?

1 Answers  


Who invented turbo c++?

1 Answers  


Categories