9. What will be the output of the following Java program? 1. class exception_handling 2. 3. public static void main(String args) 4. 5. try 6. 7. int i, sum; 8. sum = 10; 9. for (i = -1; i


9. What will be the output of the following Java program?<br>1.<br>class exception_handling<br>2.<br>3.<br>public static void main(String args)<br>4.<br>5.<br>try<br>6.<br>7.<br>int i, sum;<br>8.<br>sum =<br>10;<br>9.<br>for (i = -1; i < 3 ;++i)<br>%3D<br>10.<br>sum =<br>(sum / i);<br>11.<br>12.<br>catch(ArithmeticException e)<br>13.<br>14.<br>System.out.print(

Extracted text: 9. What will be the output of the following Java program? 1. class exception_handling 2. 3. public static void main(String args) 4. 5. try 6. 7. int i, sum; 8. sum = 10; 9. for (i = -1; i < 3="" ;++i)="" %3d="" 10.="" sum="(sum" i);="" 11.="" 12.="" catch(arithmeticexception="" e)="" 13.="" 14.="" system.out.print("0");="" 15.="" 16.="" system.out.print(sum);="" 17.="" 18.="" a)="" 0="" b)="" 05="" c)="" compilation="" error="" d)="" runtime="">

Jun 10, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here