You are given integers and you have to print a permutation of \{1,2,...,n\}.
such that
is exactly or say there is not any valid permutation.
use randomized algorithm
Here denotes Minimum Excluded Integer.
The first line of contains a single integer (1\le t\le 10^3) — the total number of test cases.
In each test case there will be two integers (2\le n\le 10^5) and (0\le k\le 10^9) — the length of the permutation and the desired .
It's guaranteed that \sum n \le 10^6 overall tests.
If there is a valid permutation then print it and if there isn't any valid permutation then print .
Example 1
In first test case \text{MEX}(1\mod 2)=0
Subtask ( points) : (k<2)
Subtask ( points) : (n\le 8)
Subtask ( points) : No additional constraints.