Suppose we have 8 rows where each element in a row is either zero or one. I want to compare rows to count differences in this way:
row1 with row2 ; row1 with row 3; row1 with row4; row2 with rows 3; row2 with row4; row3 with row4.
So how can I do that in repetition manner to repeat doing that for row5,6,7, and 8 together. note that the number of different elements between any two rows should be stored in a matrix where in our case here we should have 6 rows in the differences matrix where each row store the number of differences between two rows in the main matrix.