posted 22 years ago
And had it not thrown any exceptions , it would have printed just 4 ( the finally block ).
Ans : It will print 1,4,5
I feel that it will print 1,2 and 4 because when 5 is divided by 0, ArithmeticException is caught in the catch block.As there is not 'return' after the first catch, it will pass on the statement to second catch,which will print 2.After that there is a return statement, which will lead to the finally statement which will print 4
Please help
Sonir[/qb]<hr></blockquote>
[ January 17, 2002: Message edited by: raghav mathur ]