
快速幂 逆元
♡-流浪孩
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
Educational Codeforces Round 98 (Rated for Div. 2)------Radio Towers
题目 There are n+2 towns located on a coordinate line, numbered from 0 to n+1. The i-th town is located at the point i. You build a radio tower in each of the towns 1,2,…,n with probability 12 (these events are independent). After that, you want to set the s原创 2020-11-21 10:24:44 · 168 阅读 · 0 评论 -
2019 CCPC 秦皇岛 Gym - 102361F(HDU - 6736 ) ------ Forest Program
题目 The kingdom of Z is fighting against desertification these years since there are plenty of deserts in its wide and huge territory. The deserts are too arid to have rainfall or human habitation, and the only creatures that can live inside the deserts are原创 2020-09-26 19:18:56 · 218 阅读 · 0 评论 -
快速幂快速乘(poj 1845, hdu1575)
快速幂||快速乘 求(a^b)%p或(a*b)%p 例如:因为7 = 4 + 2 + 1,那么 5^7 = 5^(4 + 2 + 1) = 5^4 * 5^2 * 5^1 幂: 57=5×56=5×(52)3… 乘: 5×7=5+5×6=5+(5×2)×3… #include<stdio.h> #define ll long long ll quick_po...原创 2019-12-29 10:24:45 · 136 阅读 · 0 评论 -
cy的上升序列
排列组合 、 逆元、快速幂 题目来源:中北大学2019年新生赛 题目: 请构造一个长度为n的非严格递增序列,序列中每个元素大小都属于[1, m],但是这个问题太简单了,于是cy想知道有多少种合法的方案数,并且由于答案可能很大,故你需要将答案取模998244353 输入: 输出: 样例: 输入: ...原创 2019-12-02 18:26:07 · 188 阅读 · 0 评论