+ 3
Is there any way to loop through a nĂn matrix like a snail?
Imagine we have a 3Ă3 matrix and I want to loop through the indexes like first I go through the first row, then the last column, then the last row, then the first column and like this way, reach the inner index. Is there anyway?
1 Answer
+ 2
have look at â https://www.geeksforgeeks.org/print-a-given-matrix-in-spiral-form/