What exception type does the following program throw?

```
public class Test {
public static void main(String[] args) {
String s = "abc";
System.out.println(s.charAt(3));
}
}```
a. ArithmeticException
b. ArrayIndexOutOfBoundsException
c. StringIndexOutOfBoundsException
d. ClassCastException
e. No exception


c

Computer Science & Information Technology

You might also like to view...

Carefully distinguish the using directive

using namespace std; from the using directive using std::cout;

Computer Science & Information Technology

Use a(n) ____ to maintain constant power to a file server in the event of a power problem.

A. UPS B. surge protector C. power strip D. encryption program

Computer Science & Information Technology

If a variable is declared with the Public ____________________ specifier, it can be used by all instances of a Form's class.

Fill in the blank(s) with the appropriate word(s).

Computer Science & Information Technology

When defining a variable to be used to hold values that the user enters in a TextBox object, the declaration statement should have ____ at the end of the statement.

A. As Char B. As Char Type C. As String D. As String Type

Computer Science & Information Technology