CSU - 1162 Balls in the Boxes (快速幂,注意初始值范围)
#include<cstdio>
#include<iostream>
using namespace std;
typedef long long LL;
LL MOD;
LL fastpow(LL a, LL b) {
LL ans = 1;
a = a%MOD;//注意a初始可能大于MOD-1,(wa在此)
for (; b; b >&...
原创
2018-05-12 19:56:32 ·
251 阅读 ·
0 评论