Consider the following program…
class ArrayTest
{
public static void main(String[] args)
{
int ia[][] = { {1, 2}, null };
for (int i = 0; i < 2; i++)
for (int j = 0; j < 2; j++)
System.out.println(ia[i][j]);
}
}
Which of the following statements are true?
a. It will not compile.
b. It will throw an ArrayIndexOutOfBoundsException at Runtime.
c. It will throw a NullPointerException at Runtime.
d. It will compile and run without throwing any exceptions.
e. None of the above.
Sem compilar einh !!!
Valeu !!!