By Felipe C. Ochial, URI Brazil
Armandinho has a bit boring friend , named Laércio. When they play the game of master says, a game where someone gives an order and someone fulfills it, and instead of giving nice orders like climbing a tree, jumping the wall, doing a handstand or organizing manifestations to overthrow the government (regardless of who is in power) he always asks for something dull. In his last game, Laércio demanded that Armandinho order a list of numbers, so that only the odd numbers appear and the first item is the largest, the second is the smallest, the third is the second largest, the fourth is the second smaller, and so on. As doing this by hand is very annoying, Armandinho sought your help.
The input consists of an integer N representing the number of test cases ( 1<N<1000 ). Each test case begins with an integer M, which represents the size of the list (0<M<100). followed by M integers Mi (0<Mi < 1000) that represent Laércio's list.
Print the ordered list as Laércio requested, with a space between the values, breaking a line after each test case.
Input Sample | Output Sample |
3 10 1 2 3 4 5 6 7 8 9 10 7 2 4 6 8 10 12 14 4 9 7 77 63 |
9 1 7 3 5 77 7 63 9 |