Function to print the elements of the matrix in row - wise manner
static void printMatrix ( List < List < int > > a ) { foreach ( List < int > x in a ) { foreach ( int y in x ) { Console . Write ( y + " ▁ " ) ; } Console . WriteLine ( ) ; } }