上一页 1 ··· 18 19 20 21 22 23 24 25 26 ··· 37 下一页
摘要: #include#include#include#includeusing namespace std;typedef unsigned long long ull;int main(){ int i,j,n; ull f[35],a[35],g[35]; a[0]... 阅读全文
posted @ 2015-06-04 17:55 xryz 阅读(81) 评论(0) 推荐(0) 编辑
摘要: #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std;const... 阅读全文
posted @ 2015-06-03 22:07 xryz 阅读(111) 评论(0) 推荐(0) 编辑
摘要: #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std;int m... 阅读全文
posted @ 2015-06-02 22:48 xryz 阅读(87) 评论(0) 推荐(0) 编辑
摘要: #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std;const... 阅读全文
posted @ 2015-06-02 21:48 xryz 阅读(92) 评论(0) 推荐(0) 编辑
摘要: #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std;const... 阅读全文
posted @ 2015-06-01 22:02 xryz 阅读(109) 评论(0) 推荐(0) 编辑
摘要: 法一直接暴力枚举a和b的值,法二扩展欧几里德算法。#include #include #include #include #include #include #include #include #include #include #include #include #include ... 阅读全文
posted @ 2015-05-27 21:27 xryz 阅读(135) 评论(0) 推荐(0) 编辑
摘要: 题意:让你求费伯纳西数列的第a的b次方项模n的结果。由于是每一项都对n取模,所以不同的n值都会对应一个周期,只要循环一下。当前项等于f1,前一项等于f0时就可以跳出循环了。 a的b次方,可以用幂取模的知识,快速分治求出。 注意第二个样例a要先模一下周期,不然会有溢出。 刚开是long... 阅读全文
posted @ 2015-05-27 12:51 xryz 阅读(96) 评论(0) 推荐(0) 编辑
摘要: #include#include#includeusing namespace std;bool cmp(int a,int b){ return a>b;}int main(){ int i,n,exp[1024],a[10],ans,cnt,now; while... 阅读全文
posted @ 2015-05-26 14:35 xryz 阅读(98) 评论(0) 推荐(0) 编辑
摘要: 就是样例第二组数据超过long long的数据范围,所以特判一下就好了。#include#includeint main(){ int n; long long int a,b,t; scanf("%d",&n); while(n--) { ... 阅读全文
posted @ 2015-05-26 14:06 xryz 阅读(79) 评论(0) 推荐(0) 编辑
摘要: 应该是从上周六开始看这本书,起因是其他人发的一张书中内容截图。作者讲到技能的反面中的总结部分——如何考察一个人是否精通魔方:a.给面试者一个各面打乱颜色的魔方;b.要求他把六面还原;c.如果还原了,要求他把魔方恢复成我最初给他的那个混乱的局面,必须一模一样。看到这些,最近自己也在思考这个问题,自己学... 阅读全文
posted @ 2015-05-23 15:03 xryz 阅读(199) 评论(0) 推荐(0) 编辑
上一页 1 ··· 18 19 20 21 22 23 24 25 26 ··· 37 下一页