Challenge cum problem in C/C++
1 2 3 4 5
16 17 18 19 06
15 24 25 20 07
14 23 22 21 08
13 12 11 10 09
simmilarly for n=6 it should be
1 2 3 4 5 6
20 21 22 23 24 7
19 32 33 34 25 8
18 31 36 35 26 9
17 30 29 28 27 10
16 15 14 13 12 11
and so on.
The code should be only in C/C++.
Let's see who got the solution first.