Construct a square matrix of size satisfying the following conditions,
If it is possible to build such a matrix, print the matrix otherwise print .
First line of input consists of a single integer , the number of test cases
Each test case consists of one line. First and only line of the test case contains , the dimension of the matrix. .
Print the matrix if possible, otherwise print . If there are multiple possible answers, anyone would be acceptable.
2 2 3
-1 1 3 2 3 2 1 2 1 3
We call a sequence of integers permutation if every integer from 1 to |A| appears exactly once in the sequence, where denotes the length of the sequence.