Is there an efficient way to find the indices of the rows that are repeating? For instance if the 2d array is:
2 5 1 2 2 5 1 2 2 3 1 2
I need a vector output like this:
0 1 0 1 4 1
where each entry points to the row index of original array.