Prints 1 to n^2 numbers in a spiral order.
For printing, we start writing from zero,zero index towards Right direction then to Down then to Left and lastly to Right. Till we reach the last point. In doing so,we keep a track of the rows and columns that are traversed.