Create focal point for new Sub Array

$25.00

Category:

Description

for (int i = 0; i < mainArray.length – 4; i++)

{

for (int j = 0; j < mainArray.length – 4; j++)

{

// Create focal point for new subArray to revolve around, hence creating a new subArray at position [i][j] within the main array.

subArray[0][0] = mainArray[i][j];

// Fill out the rest of each subArray as a 4×4 matrix.

subArray[i][j] = mainArray[i][j];

}

}