C Sharp (C#) - Exception Handling
Why might a developer prefer using a when clause in a catch block instead of nested if statements inside the catch block?
Why might a developer prefer using a when clause in a catch block instead of nested if statements inside the catch block?
when clause filters exceptions before the catch block runs, so only matching exceptions enter the block.15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions