Codeforces Round 681 (Div. 2, based on VK Cup 2019-2020 - Final)
A
Kids Seating
Codeforces
800
原题
←B →
翻译中…

Today the kindergarten has a new group of $n$ kids who need to be seated at the dinner table. The chairs at the table are numbered from $1$ to $4n$. Two kids can't sit on the same chair. It is known that two kids who sit on chairs with numbers $a$ and $b$ ($a \neq b$) will indulge if:

翻译中…
  1. $gcd(a, b) = 1$ or,
  2. $a$ divides $b$ or $b$ divides $a$.
翻译中…

$gcd(a, b)$ — the maximum number $x$ such that $a$ is divisible by $x$ and $b$ is divisible by $x$.

翻译中…

For example, if $n=3$ and the kids sit on chairs with numbers $2$, $3$, $4$, then they will indulge since $4$ is divided by $2$ and $gcd(2, 3) = 1$. If kids sit on chairs with numbers $4$, $6$, $10$, then they will not indulge.

翻译中…

The teacher really doesn't want the mess at the table, so she wants to seat the kids so there are no $2$ of the kid that can indulge. More formally, she wants no pair of chairs $a$ and $b$ that the kids occupy to fulfill the condition above.

翻译中…

Since the teacher is very busy with the entertainment of the kids, she asked you to solve this problem.

翻译中…

Input

翻译中…

The first line contains one integer $t$ ($1 \leq t \leq 100$) — the number of test cases. Then $t$ test cases follow.

翻译中…

Each test case consists of one line containing an integer $n$ ($1 \leq n \leq 100$) — the number of kids.

翻译中…

Output

翻译中…

Output $t$ lines, which contain $n$ distinct integers from $1$ to $4n$ — the numbers of chairs that the kids should occupy in the corresponding test case. If there are multiple answers, print any of them. You can print $n$ numbers in any order.

翻译中…

样例

Input #1
3
2
3
4
Output #1
6 4
4 6 10
14 10 12 8
InputCopy OutputCopy
题目信息
题号
1443A
时间限制
2 s
内存限制
256 MB
标签
构造
数学

题面与样例版权归 Codeforces 及出题人所有;中文翻译由 AI 生成(CI 管线),如有出入请以原文为准。