QOJ.ac

QOJ

حد الوقت: 1 s حد الذاكرة: 32 MB مجموع النقاط: 100

#11047. 拜特兰的重建

الإحصائيات

大家动起来!Bytean 在一场毁灭性的战争后需要重建!

你需要为 Bytean 的各个城市分配邮政编码。每个城市应获得一个邮政编码——一个不超过 $10^{9}$ 的正整数。不同的城市必须分配不同的邮政编码。

Bytean 邮政系统的组织方式非常奇特;只有当两个城市的邮政编码有大于 1 的公约数时,信件才能从城市 $A$ 发送到城市 $B$。显然,你的目标之一是确保在分配邮政编码后,任意两个城市之间都可以直接发送信件。

此外,新的反腐败法要求:对于任意包含超过半数 Bytean 城市的城市集合,该集合中所有城市的邮政编码不能有任何大于 1 的公约数。

请编写一个程序:

  • 从标准输入读取 Bytean 的城市数量,
  • 为每个 Bytean 城市分配一个邮政编码,
  • 将分配结果写入标准输出。

输入格式

输入的第一行也是唯一一行包含一个整数 $n$ ($4 \le n \le 100$),表示 Bytean 的城市数量。

输出格式

输出应包含恰好 $n$ 行。第 $i$ 行应包含一个不超过 $10^{9}$ 的正整数,即第 $i$ 个 Bytean 城市的邮政编码。你可以假设对于每个可能的输入,都存在一种有效的邮政编码分配方案。如果存在多种正确的解决方案,输出其中任意一种即可。

样例

输入 1

5

输出 1

714
2090
4485
29029
215441

Discussions

About Discussions

The discussion section is only for posting: General Discussions (problem-solving strategies, alternative approaches), and Off-topic conversations.

This is NOT for reporting issues! If you want to report bugs or errors, please use the Issues section below.

Open Discussions 0
No discussions in this category.

Issues

About Issues

If you find any issues with the problem (statement, scoring, time/memory limits, test cases, etc.), you may submit an issue here. A problem moderator will review your issue.

Guidelines:

  1. This is not a place to publish discussions, editorials, or requests to debug your code. Issues are only visible to you and problem moderators.
  2. Do not submit duplicated issues.
  3. Issues must be filed in English or Chinese only.
Active Issues 0
No issues in this category.
Closed/Resolved Issues 0
No issues in this category.