RosettaCodeData/Task/Exceptions/C-sharp/exceptions-3.cs
2023-07-01 13:44:08 -04:00

11 lines
171 B
C#

try {
foo();
}
catch (MyException e)
{
// handle exceptions of type MyException and derived
}
catch
{
// handle any type of exception not handled by above catches
}