Given a matrix mat of size M*N. Traverse and print the matrix in spiral form.
The first line of the input contains a single integer T, denoting the number of test cases. Then T test cases follow. Each testcase has 2 lines. First line contains M and N respectively separated by a space. Second line contains M*N values separated by spaces.
Elements when travelled in Spiral form, will be displayed in a single line.
1 <= T <= 100
2 <= M,N <= 10
0 <= Ai <= 100