1.  Which of the following statements are correct about exception handling in C#.NET ?
1. If our program does not catch an exception then the .NET CLR catches it.
2. It is possible to create user-defined exceptions.
3. All types of exceptions can be caught using the Exception class.
4. CLRExceptions is the base class for all exception classes.
5. For every try block there must be a corresponding finally block.


1 and 2 only
1, 2 and 3 only
4 and 5 only
All of above


Answer

 Option

No answer description available for this question.

Workspace

Report
Mail id: Report Error:

Answer Workspace Report

2.  Which of the following statements are correct about exception handling in C#.NET ?
1. If an exception occurs then the program terminates abruptly without getting any chance to recover from the exception.
2. No matter whether an exception occurs or not, the statements in the finally clause (if present) will get executed.
3. A program can contain multiple finally clauses.
4. A finally clause is written outside the try block.
5. finally clause is used to perform clean up operations like closing the network/database connections.


1 only
2 only
2 and 5 only
3 and 4 only


Answer

 Option

No answer description available for this question.

Workspace

Report
Mail id: Report Error:

Answer Workspace Report

3.  Which among the following is NOT considered as .NET Exception class ?
a. Exception
b. StackUnderflow Exception
c. File Found Exception
d. Divide By zero Exception


a, b
b, c
c, d
a, d


Answer

 Option

No answer description available for this question.

Workspace

Report
Mail id: Report Error:

Answer Workspace Report

4.  Which of the following is the correct statement about exception handling in C#.NET ?
a. finally clause is used to perform cleanup operations of closing network and database connections
b. a program can contain multiple finally clauses
c. The statement in final clause will get executed no matter whether an exception occurs or not
d. All of the above mentioned


a, b
a, c
b, d
b, c


Answer

 Option

No answer description available for this question.

Workspace

Report
Mail id: Report Error:

Answer Workspace Report

5.  Select the statements which describe the correct usage of exception handling over conventional error handling approaches ?


As errors can be ignored but exceptions cannot be ignored
Exception handling allows separation of program’s logic from error handling logic making software more reliable and maintainable
try – catch – finally structure allows guaranteed cleanup in event of errors under all circumstances
All of the mentioned


Answer

 Option

No answer description available for this question.

Workspace

Report
Mail id: Report Error:

Answer Workspace Report