Multiple choice technology programming languages

The keyword used along with try catch block to execute a part of code even if an exception is not caught is

  1. Finalize

  2. Finally

  3. Final

  4. Financial

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

The finally keyword is used with try-catch blocks to execute code that must run whether an exception is caught or not. It is typically used for cleanup operations like closing files or releasing resources.