QOJ.ac

QOJ

Límite de tiempo: 1 s Límite de memoria: 2048 MB Puntuación total: 100

#8250. 镁补充剂

Estadísticas

在最近的一次医生预约中,Brandon 被诊断出镁缺乏。医生建议他每天摄入一定量的镁(单位为皮克)。医生可以开出药丸,每颗药丸的镁含量可以是 1 到 $k$ 皮克之间的任意整数。然而,Brandon 不喜欢吃药,因此他拒绝任何需要每天服用过多药丸的处方。

你的任务是找出所有 Brandon 可能接受的处方。注意,开给 Brandon 的所有药丸必须具有相同的剂量。

输入格式

输入包含一行,包含三个整数 $n, k$ 和 $p$ ($1 \le n, k, p \le 10^{11}$),其中 $n$ 是 Brandon 每天必须摄入的镁总量(单位为皮克),$k$ 是每颗药丸中镁含量的最大值(单位为皮克),$p$ 是 Brandon 每天愿意服用的药丸数量上限。

输出格式

第一行输出一个整数,表示 Brandon 可能接受的处方数量。

在接下来的每一行中,输出一个整数,表示该处方中每颗药丸的镁含量(单位为皮克)。请按升序输出这些处方。

样例

样例输入 1

6 6 4

样例输出 1

3
2
3
6

样例输入 2

6 2 3

样例输出 2

1
2

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.