Introduction - If you have any usage issues, please Google them yourself
Magic square matrices
Problem Description:
The Magic Quadrant is a very interesting digital matrix, Bagua Zhen Jiu Gong in early on with the famous magic square related.
Magic square is defined as:
1 to N* N N* N integer fill the grid, each row and column and diagonal sum of the numbers must be equal.
Your company s top programmers as gossip, you now need to solve a problem, any odd-order magic square to find out.
Input:
Input consists of multiple test sets, each act a positive odd N (1 <= N <1000), 0 end as input and does not require treatment.
Output:
For each input N, it corresponds to the output of a magic square of order N, if there is more than one, any one can.
Every magic square is N* N matrix,
For each magic square, magic square of each line of output line between the numbers in each row with one or more separated by spaces. Between the different magic squares separated by a blank line.