1
|
2
|
3
|
4
|
5
|
14
|
15
|
16
|
17
|
6
|
13
|
20
|
19
|
18
|
7
|
12
|
11
|
10
|
9
|
8
|
1
|
2
|
3
|
4
|
5
|
6
|
7
|
8
|
9
|
10
|
11
|
12
|
13
|
14
|
15
|
16
|
17
|
18
|
19
|
20
|
Am sure there is a much better and efficient way to solve this problem. Here is my version of the implementation (recursion approach) that works for any n*n matrix. Details in the self-explanatory Java code:
No comments:
Post a Comment