This repository demonstrates an example of an ArrayIndexOutOfBoundsException in Java, a relatively uncommon error compared to NullPointerExceptions. This specific error occurs when you attempt to access an array element using an index that is either negative or greater than or equal to the array's length.
The UncommonErrorExample.java file shows the error, while UncommonErrorSolution.java provides a solution demonstrating how to handle the exception using a try-catch block.
- Clone this repository.
- Compile and run
UncommonErrorExample.java.