You are given an n x n 2D matrix representing an image.
Rotate the image by 90 degrees (clockwise).
Follow up: Could you do this in-place?
Solution
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
|
You are given an n x n 2D matrix representing an image.
Rotate the image by 90 degrees (clockwise).
Follow up: Could you do this in-place?
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
|