i have two matrices, lets say
A=[ 1 0 0 0 5 1 1 1 0 8 1 4 3 2 10 2 0 1 0 8 2 1 2 1 7] B = 1 0 0 0 10 1 3 5 7 0 1 5 7 8 2 1 6 8 9 3 1 1 1 0 3 1 5 6 8 7 1 4 3 2 10 2 0 1 0 3 2 5 6 8 7 2 6 8 9 3 2 1 2 1 4 2 3 5 7 0
all the rows of matrix A but are somewhere in the matrix B but the last elements in rows are different(last column of A&B) , the only constraint about matrices A and B is that the elements of first columns of matrices A&B are either 1 or 2. i want to compare elements of first 4 elements at each row from matrix B with matrix A, and if the first 4 elements match, take the difference of last element.
can somebody please help me.
thank you
Best Answer