How does a try statement determine which catch clause
should be used to handle an exception?

Answer Posted / guest

when an exception is thrown with in the body of the try
statement then the catch clauses of the try statement are
examined in the order in which they appear.The first catch
clause that is capable of handling the exception is caught
and the remaining are ignored.

Is This Answer Correct ?    8 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the Scope of Static Variable?

728


How to restrict a member of a class from inheriting by its sub classes?

798


How to pass arraylist to stored procedure in java?

546


What is the order of arraylist in java?

605


What are the states of thread in java?

510






If a method is declared as protected, where may the method be accessed in java programming?

496


Can we execute java program without main method?

518


What is the default size of load factor in hashing based collection?

561


Is minecraft 1.15 out?

545


Can a class extend more than one class?

609


Can java cast null?

595


Why volatile is used in java?

530


Can a class be private or protected in java?

556


How to perform bubble sort in java?

588


What data type is true or false?

571