Vidyalelo
Java Programming · Q20

Exceptions

Programming · Java Programming · question 20

Q20

What is the result of the following code snippet?try int result = 10 / 0; catch (ArithmeticException e) System.out.println("Arithmetic Exception!"); finally System.out.println("Finally Block!");

A.
No output
B.
Finally Block!
C.
Arithmetic Exception!
D.
Arithmetic Exception!
Finally Block!
Answer

Answer: Option D

Solution

Answer: Option D
No explanation is given for this question Let's Discuss on Board