Need help running this code, I need to find the error so I can fix it. Thanks! the error receive is Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 6 at DebuggingExercise.main(DebuggingExercise.java:13)
import java.io.*;
public class DebuggingExercise {
public static void main(String[] args)
{
int[][] testArray = new int[5][6];
for(int i=0;i<5;i++)
{
for(int j=1; j<=6; j++)
testArray[i][j] = (i+1)*j;
}
}
}