摘要: 题意 要求一个 $O(\sqrt P) - O(1)$ 的快速幂。 幂可以用扩展欧拉定理规约到 $[1,P-1]$ 中。 分析 分块。定个阈值 $B = \sqrt P$ + 1。 $a^t = a^{t\bmod B} \cdot a^{B \times \lfloor\dfrac{t}{B}\r 阅读全文
posted @ 2022-09-24 13:12 Lates 阅读(41) 评论(0) 推荐(0)