There are N pancakes of distinct sizes stacked from top to bottom. The goal is to arrange them by size so that the smallest pancake is on top and the largest pancake is on the bottom; in other words, the stack should become 1, 2, ..., N from top to bottom.
One operation chooses an integer k and reverses the order of the top k pancakes. After the operation, the pancake that was in position k becomes the top pancake, and the previous top pancake moves to position k.

Given the initial stack, output a sequence of flips that sorts it. For each test case, you may use at most max(0, 2N - 3) flips.
The first line contains the number of test cases T.
Each test case is given on one line. The first number is the number of pancakes N, followed by N integers describing the pancake sizes from top to bottom.
N is at most 30. The pancake sizes are distinct integers from 1 to N.
For each test case, print one line. First print the number of flips K, then print the prefix lengths to flip in the order they should be performed.
If there is more than one valid sequence, you may print any one of them.