CF2039A.Shohag Loves Mod

传统题 时间 2000 ms 内存 256 MiB 3 尝试 1 已通过 1 标签

Shohag Loves Mod

Shohag has an integer nn. Please help him find an increasing integer sequence 1≤a1<a2<…<an≤1001 \le a_1 \lt a_2 \lt \ldots \lt a_n \le 100 such that ai mod i≠aj mod ja_i \bmod i \neq a_j \bmod j ∗^{\text{∗}} is satisfied over all pairs 1≤i<j≤n1 \le i \lt j \le n.

It can be shown that such a sequence always exists under the given constraints.

∗^{\text{∗}}a mod ba \bmod b denotes the remainder of aa after division by bb. For example, 7 mod 3=1,8 mod 4=07 \bmod 3 = 1, 8 \bmod 4 = 0 and 69 mod 10=969 \bmod 10 = 9.

Input

The first line contains a single integer tt (1≤t≤501 \le t \le 50) — the number of test cases.

The first and only line of each test case contains an integer nn (2≤n≤502 \le n \le 50).

Output

For each test case, print nn integers — the integer sequence that satisfies the conditions mentioned in the statement. If there are multiple such sequences, output any.

Note

In the first test case, the sequence is increasing, values are from 11 to 100100 and each pair of indices satisfies the condition mentioned in the statement:

  • For pair (1,2)(1, 2), a1 mod 1=2 mod 1=0a_1 \bmod 1 = 2 \bmod 1 = 0, and a2 mod 2=7 mod 2=1a_2 \bmod 2 = 7 \bmod 2 = 1. So they are different.
  • For pair (1,3)(1, 3), a1 mod 1=2 mod 1=0a_1 \bmod 1 = 2 \bmod 1 = 0, and a3 mod 3=8 mod 3=2a_3 \bmod 3 = 8 \bmod 3 = 2. So they are different.
  • For pair (2,3)(2, 3), a2 mod 2=7 mod 2=1a_2 \bmod 2 = 7 \bmod 2 = 1, and a3 mod 3=8 mod 3=2a_3 \bmod 3 = 8 \bmod 3 = 2. So they are different.

Note that you do not necessarily have to print the exact same sequence, you can print any other sequence as long as it satisfies the necessary conditions.

Samples

2
3
6
2 7 8
2 3 32 35 69 95

在线编程 IDE

建议全屏模式获得最佳体验