public class Main {
public static void main(String[] args) {
try {
int[] numbers = {10, 20, 30};
System.out.println(numbers[5]);
} catch (ArrayIndexOutOfBoundsException e) {
System.out.println("Sorry, that index does not exist.");
}
System.out.println("The program keeps running.");
}
}
// Output:
// Sorry, that index does not exist.
// The program keeps running.