![](https://img-blog.csdnimg.cn/20201014180756925.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
数据结构---快速幂
AI蜗牛之家
北航烟酒僧~ 百度、腾讯自然语言处理算法工程师~
展开
-
快速求幂
#include #include using namespace std;int main(){ int m,n; while(scanf("%d %d", &m, &n)!=EOF) { if(m==0&&n==0) break; int a[3],b[3],c[3]={0,0,0},i; for(i=0;i<3;i++) {原创 2014-10-23 20:28:07 · 1045 阅读 · 0 评论 -
快速幂与矩阵—>快速矩阵幂
//HOJ 3493/*===================================*/|| 快速幂(quickpow)模板 || P 为等比,I 为单位矩阵|| MAX 要初始化!!!!||/*===================================*//*********************************************原创 2014-10-25 13:14:17 · 1209 阅读 · 0 评论 -
湖南多校对抗赛---Jerry's trouble
Description Jerry is caught by Tom. He was penned up in one room with a door, which only can be opened by its code. The code is the answer of the sum of the sequence of number written on the door.原创 2015-03-29 08:54:49 · 1551 阅读 · 0 评论 -
HDU 5241 Friends(大数+快速幂)
FriendsTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 262144/262144 K (Java/Others)Total Submission(s): 1356 Accepted Submission(s): 639Problem DescriptionMike has many fri原创 2017-04-30 21:59:08 · 1250 阅读 · 0 评论 -
2015上海邀请赛
之前除了水了几道题,博客里整理了几道,其他的以后有机会补上 Overview ProblemStatusRank (05:00:00)6 CommentsSettingFavoriteClone Stat#OriginTitle原创 2017-05-01 22:20:15 · 1080 阅读 · 0 评论 -
再论斐波那契数列(矩阵&快速幂)
以前已经做过斐波那契数列了,想想当时做的时候原创 2014-10-25 12:43:57 · 1198 阅读 · 0 评论 -
HZAU 1202 GCD( 斐波那契数列+矩阵快速幂)
Problem D: GCDTime Limit: 1 Sec Memory Limit: 1280 MBSubmit: 194 Solved: 27[Submit][Status][Web Board]DescriptionInput The first line is an positive integer T . (1<=T<=原创 2017-04-24 21:47:05 · 1250 阅读 · 0 评论