if n=4 then o/p is 1 2 3 4 12 13 14 5 11 16 15 6 10 9 8 7
if n=5
1 2 3 4 5 16 17 18 19 6 15 24 25 20 7 14 23 22 21 8 13 12 11 10 9
there is no space between numbers (just for clarification i had taken).
Aucun commentaire:
Enregistrer un commentaire