1.

A single try block must be followed by which of these?(a) finally(b) catch(c) Both finally & catch(d) None of the mentionedThe question was asked in an internship interview.This intriguing question comes from Exceptions of Type Finally and Built in Exceptions in section Indexers and Exception Handling of C#

Answer»

Correct ANSWER is (c) Both FINALLY & catch

Explanation: TRY block can be FOLLOWED by any of finally or catch block, try block checks for exceptions and work is performed by finally and catch block as per the exception.



Discussion

No Comment Found

Related InterviewSolutions