This loop is supposed to find the maximum element of a secondary diagonal of a 4X4 matrix. But I can't really understand it fully. Why is i=0 and j=2? Is there an easier way of looping through the secondary diagonal?
1 2 3 4 5 6 7
for (int i = 1, j = 2; i < 4, j >= 0; i++, j--)
{
if (max < a[i][j])
{
max = a[i][j];
}
}