标签:mic turn return pre bsp amp span color while
快速乘(防止爆long long)
long long q_mul( long long a, long long b, long long mod ) //快速计算 (a*b) % mod { long long ans = 0; while(b) { if(b & 1) { b--; ans =(ans+ a)%mod; } b /= 2; a = (a + a) % mod; } return ans; }
标签:mic turn return pre bsp amp span color while
原文地址:http://www.cnblogs.com/gggyt/p/7291347.html