Suresh is a strange boy. He neither likes an array in ascending order nor in descending order. Then what does he like?
He likes an array if and only if it is mixed i.e, both ascending and descending. He has got lots of arrays from his friends. But he doesn't like any of them. Now he plans to re-construct those arrays :
He takes an array :
1. finds the smallest and largest integers among them
2.places the smallest followed by the largest number.
3.In a similar manner, he finds smallest and largest numbers among the remaining numbers and places them next to the previous numbers until all the numbers are over .
Input format:
T , the number of test cases
N , the number of elements in th array
A , the array
Output format: Output the array
In test case 1:
The array is 6 8 3 9 9 2 6 8 1 . Here the smallest and the largest number in the array are 1 and 9 respectively.
Now the newly formed array is 1 9
Remaining elements in the array are 6 8 3 9 2 6 8 . Here the smallest and largest elements among the remaining elements are 2 and 9 respectively.
Now the array is 1 9 2 9
In the same way, from the remaining 6 8 3 6 8 we have 3 as smallest and 8 as largest.
Now the array is 1 9 2 9 3 8
Similarly we arrive at the array 1 9 2 9 3 8 6 8 6