摘要:
1.gcd 2.扩展gcd )extend great common divisor 3.求a关于m的乘法逆元 补充:求逆元还可以用 ans=abmodm=(amod(m⋅b))/bans=abmodm=(amod(m⋅b))/b 4.快速幂quick power ll func(ll a,ll b 阅读全文
posted @ 2019-01-08 10:26
DWVictor
阅读(480)
评论(0)
推荐(1)
摘要:
map m; //分解质因数 //k为1或-1 void fun(int n, int k) { for (int i = 2; i 1) { m[n] += k; } } //大数快速幂取模 LL quick_pow(LL a, LL b) { LL ret = 1; while (b) { if ... 阅读全文
posted @ 2019-01-08 10:25
DWVictor
阅读(372)
评论(0)
推荐(0)
摘要:
阅读全文
posted @ 2019-01-08 10:17
DWVictor
阅读(154)
评论(0)
推荐(0)

浙公网安备 33010602011771号