farmpiggie and Subset Sum
Description:
For a permutation of even length, you can do the following process:
Initialize a counter . For each from to , either add to , subtract from , or do nothing. Let the final value of the counter be . Formally, for each , consider the set and choose some . Set .
You are given a single even integer . Find any permutation of length so that regardless of the operations chosen, the final value will not be 1.
Input Each test contains multiple test cases. The first line contains the number of test cases (). The description of the test cases follows.
The first and only line of each test case contains a single even integer () — the length of the desired permutation.
Output For each test case, output integers () — a permutation satisfying the conditions.
If there are multiple solutions, print any of them.