How can we loop in a matrix anti clockwise, starting at (0,0) and determine what would be the last element in the traversal? Not it can be an NxM matrix.
Asked
Active
Viewed 248 times
0
-
I think you start by doing a few examples by hand. Square and rectangular. Even and odd values for `M` and `N`. – user3386109 Oct 21 '22 at 00:03
-
see https://stackoverflow.com/a/33688562/2521214 – Spektre Oct 21 '22 at 06:33