P15423 Backlight

Description

Given $n$, construct a strictly decreasing sequence $a_i$ of length $n$ such that for all $i\in[1, n - 2]$, $\gcd(a_i, a_{i+1})

Input Format

One line with one integer $n$, the length of the sequence.

Output Format

One line with $n$ positive integers satisfying the conditions above. In addition, it must hold that $1\le a_i\le 10^{18}$.

Explanation/Hint

For $100\%$ of the testdata, $2\le n\le 10^6$. Obviously, once you have an answer for $n=k$, you certainly have an answer for $n=k-1$. Therefore this problem has only six test cases, whose ranges and scores are as follows: | Test Case | $n=$ | Score | |:-:|:-:|:-:| | $1$ | $10$ | $10$ | | $2$ | $60$ | ^ | | $3$ | $100$ | ^ | | $4$ | $3000$ | $20$| | $5$ | $10^5$ | $30$ | | $6$ | $10^6$ | $20$ | Translated by QwenWork