Exception Handling.

PRE TEST :


Question 1:
The class at the top of exception class hierarchy is......

ArithmeticException
Throwable
Object
Exception


Question 2:
Exception generated in try block is caught in ....... block.
catch
throw
throws
finally


Question 3:
In which of the following package Exception class exist?
java.lang
java.util
java.file
java.io


Question 4:
Which of the following blocks execute compulsarily whether exception is caught or not.
catch
finally
throw
throws


Question 5:
Which keyword is used to specify the exception trown by method?
catch
finally
throws
all of the above.


Question 6:
Which keyword is used to explicitly throw an exception?
try
throw
catch
all of the above.


Question 7:
Which exception is thrown when divide by zero statement excuses?
ArithmeticException
NumberFormatException
NullPointerException
None of mentioned.


Number of score out of 7 = Score in percentage =