Hash Set Implementation for Matrix Row Processing

Step 1: Start processing the matrix rows