Magic square is an $n$ by $n$ square grid where each cell of the grid contains distinct integers in the range
$1, 2, \cdots, n^ 2$ , and the sum of each row, column and diagonal is equal.
To create an $n$ by $n$ magic square($n$ is odd), you have to fill in $1, 2, \cdots, n^ 2$ accordingly with the following steps:
A positive odd integer $n(n\leq1001)$
An $n\times n$ magic square which is generated by the previous steps. Notice that integers in the same row are separated by a single white space, and each row should end with a new line character(‘\n’).
|No.||Time Limit (ms)||Memory Limit (KiB)||Output Limit (KiB)||Subtasks|