Monday, 13 February 2017

UnCheckedException : NegativeArraySizeExcept





public class NegativeArraySizeExcept {

    public static void main(String args[])throws IOException
    {
        int c[]=new int[-2];        Scanner in=new Scanner(new InputStreamReader(System.in));        int b=in.nextInt();        int a[]=new int[b];    }
}

No comments:

Post a Comment