I have a 3D matrix as following:
a = [[[0, 1, 2, 3, 4, 5], [1, 2, 3, 4, 5, 6], [2, 3, 2, 3, 4, 5], [3, 2, 3, 4, 3, 4], [4, 3, 4, 5, 4, 3], [5, 4, 5, 6, 5, 4]]]
When I loop over the matrix I want the first index i to represent the row of a, the second index to represent the column an the third index k to just be 0 or 1 depending on: k = 0 in which case the value is the row index of the cell is pointing to, or the k = 1 the value is the column index.
The problem is that everyting is opposite: the index i is now representing what I want k to be, the j is the row which should be the column and k is the column.
for i in a:
#I want i to represent the row
for j in i:
#I want j to represent the column