[2024 GDCPC J] 另一个计数问题
You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.
给定一个 个点的无向图,点的编号为 。对于所有的 ,边 存在当且仅当 是 的正整数倍。定义 表示 与 是否连通:当 连通时 ,否则 。求:
$$\left(\sum_{u = 2} ^ {n - 1} \sum_{v = u + 1} ^ n f(u, v) \cdot u \cdot v\right) \bmod {998244353}$$Input
输入一行一个正整数 。保证 。
Output
输出一行一个非负整数表示答案。
4
8
当且仅当 ,故答案为 。
6
80
所有满足 的 为:。
127
23573971
2024广东省大学生程序设计竞赛(重现赛)
- Status
- Done
- Rule
- XCPC
- Problem
- 10
- Start at
- 2026-10-30 13:00
- End at
- 2026-10-30 18:00
- Duration
- 5 hour(s)
- Host
- Partic.
- 2