摘要: inline int read(){ register int x = 0, f = 1; register char ch=getchar(); while(ch<'0'||ch>'9'){ if(ch=='-') f=-1; ch=getchar(); } while(ch>='0'&&ch<= 阅读全文
posted @ 2021-12-29 22:39 tmjyh09 阅读(30) 评论(0) 推荐(0) 编辑
摘要: int f(int a, int b) { int ans = 1; int base = a; while (b) { if (b & 1)ans = base * ans; base = base * base; b >>= 1; } return ans; } 取余版本: int f(int 阅读全文
posted @ 2021-12-29 22:32 tmjyh09 阅读(52) 评论(0) 推荐(0) 编辑