Is it compulsory for a Try Block to be followed by a Catch Block in Java for Exception handling?

By ayush goel in 22 Sep 2023 | 11:26 am
ayush goel

ayush goel

Student
Posts: 346
Member since: 21 Sep 2023

Is it compulsory for a Try Block to be followed by a Catch Block in Java for Exception handling?

22 Sep 2023 | 11:26 am
0 Likes
divas goyal

divas goyal

Student
Posts: 453
Member since: 22 Sep 2023

    - It is not compulsory for a `try` block to be followed by a `catch` block in Java. You can have a `try` block without a `catch` block if you use a `finally` block or nothing after the `try`.


23 Sep 2023 | 04:33 pm
0 Likes

Report

Please describe about the report short and clearly.