Finding duplicates in 2D array - Row and Column <p>I would like to know how do I find duplicates separately - Row and Column.</p> <p>So far I think I have this for the row, haven't really tested it out. But I am kinda confuse how to find duplicates for a 2D array in column fashion? I need to implement 2 functions one to find duplicate for row and the other one to find duplicate for column.</p> <pre><code>bool uniqueRow(int square[][MAX_SIZE], int sqrSize, int i) { int j; for(i = 0; i &lt; sqrSize; ++i) { for(j = i; i &lt; sqrSize &amp;&amp; square[i][i] != square[i][j]; ++j) { if(square[i][i] == square[i][j]) return false; else return true; } } return false; } bool uniqueCol(int square[][MAX_SIZE], int sqrSize, int i) { int j; for(i = 0; i &lt; sqrSize; ++i) { for(j = i; i &lt; sqrSize &amp;&amp; square[i][i] != square[j][i]; ++j) { if(square[i][i] == square[j][i]) return false; else return true; } } } </code></pre>