Question:
What will be the output for follwing code
try
{
Console.WriteLine("Before Exception");
throw new Exception("Raising exception");
Console.WriteLine("After Exception");
}
catch(Exception e)
{
Console.WriteLine("Inside Catch");
}
finally
{
Console.WriteLine("Inside Finally");
}
Console.WriteLine("Outside Try");
Answer:
Before Exception
Inside Catch
Inside Finally
Outside Try
Showing posts with label Try Catch in c#. Show all posts
Showing posts with label Try Catch in c#. Show all posts
Tuesday, January 15, 2008
Subscribe to:
Posts (Atom)