in Education by
Which of the following should be true of the object thrown by a thrown statement? (a) Should be assignable to String type (b) Should be assignable to Exception type (c) Should be assignable to Throwable type (d) Should be assignable to Error type This question was posed to me by my school teacher while I was bunking the class. This key question is from Exception Handling in portion Exception Handling of Java Select the correct answer from above options JavaScript questions and answers, JavaScript questions pdf, JavaScript question bank, JavaScript questions and answers pdf, mcq on JavaScript pdf, JavaScript questions and solutions, JavaScript mcq Test , Interview JavaScript questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)

1 Answer

0 votes
by
The correct choice is (c) Should be assignable to Throwable type The best I can explain: The throw statement should be assignable to the throwable type. Throwable is the super class of all exceptions.

Related questions

0 votes
    Which of the following operators is used to generate instance of an exception which can be thrown using ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 25, 2021 in Education by JackTerrance
0 votes
    Which exception is thrown by read() method? (a) IOException (b) InterruptedException (c) SystemException (d ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 24, 2021 in Education by JackTerrance
0 votes
0 votes
    Which file separator should be used by MANIFEST file? (a) / (b) \ (c) - (d) // The ... questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 24, 2021 in Education by JackTerrance
0 votes
    What kind of an exception will be thrown if the string to parse is not valid JSON? (a) ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 22, 2021 in Education by JackTerrance
0 votes
0 votes
0 votes
    Which tag should be used to pass information from JSP to included JSP? (a) Using tag (b) Using ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 24, 2021 in Education by JackTerrance
...