Is there any connection between packages and exception handling in java. Means is it necessary to create a package before trying exception handling examples?
Type: Posts; User: CruiseDevice
Is there any connection between packages and exception handling in java. Means is it necessary to create a package before trying exception handling examples?
if(e.instanceof ArithmeticException)
{
System.out.println("Divide by zero");
}
if(e.instanceof ArrayIndexOutOfBounds)
{
It is showing error in there two loops.
package javaapplication6;
import java.util.Scanner;
public class JavaApplication6 {
public static void main(String[] args) {
int a,b,c;
int arr[] = new...