Why the code is executing finally block ? | Sololearn: Learn to code for FREE!
Neuer Kurs! Jeder Programmierer sollte generative KI lernen!
Kostenlose Lektion ausprobieren
0

Why the code is executing finally block ?

https://code.sololearn.com/cd5PT5DxgGMc It is executing finally. I read that after putting "System.exit(0)" in the end of try block the finally block will not be executed. -------------------------------------------Question link---------------------------------------------- https://www.interviewbit.com/java-interview-questions/#will-finally-block-be-executed-if-code-system-exit-0-is-written-at-the-end-of-try-block

26th Feb 2022, 10:00 AM
𝖆𝖙.𝖚𝕷
𝖆𝖙.𝖚𝕷 - avatar
0 Antworten