I am trying to understand the solution to rotate the N * N array at the place of 90 degrees. This question was asked before, but now it is closed - [Link] The best answer given is beautiful, but I am not able to understand it, someone can interpret these steps
It is not necessary in Ajhen, because you can swap all four elements once in the same expression: n × n matrix, n = 3: Corner: swap : 5 × 5 matrix: Corner: SWAP:
1 2 3 4 5 6 7 8 9
N / 2 = 1 ,
(N + 1) / 2 = 2 .
x = [0, 2] (0 or 1),
y = [0, 1] (0).
1 2 | 3 _____ | 4 5 6 7 8 9
1 ounce ???? 3 a 7 a 9 (1 ??? 1) ;
2 o "6 one 8 one 4 (â ???? 2) < / Code>
abcdefghijklmnopqrstu Vwxy < P>
N / 2 = 2 ,
(N + 1) / 2 = 3 .
X = [0, 3] (0 or 1 or 2),
y = [0, 2] (0 or 1).
ABC | DEFG H | I j ______ | K LMNOP QRSTUVWYY
AA ???? E y ??? Uf one ???? D â ???? T V b â ???? Jm x pg a ???? I have a ???? S â ???? QA AO ??? Ya ???? K H ??? N â ???? RL
No comments:
Post a Comment