Rotate the array clockwise#9569

Rotate the array clockwise

1 secondo
64 megabyte
Facile

Given a square two-dimensional array of size n \times n, your task is to return its elements in a clockwise spiral order.

Input

The first line of the input contains a single integer , representing the size of the array.

The following lines each contain integers, which are the elements of the array.

Output

Print the elements of the array in a clockwise spiral order.

Esempi

Esempio 1

Loading
Loading