上一页 1 ··· 12 13 14 15 16 17 18 19 20 ··· 39 下一页
摘要: Last weekend you and your friends went to visit the local farmer’s market at the town square. As you were standing around in a circle talking, you cou 阅读全文
posted @ 2018-08-29 12:18 #忘乎所以# 阅读(300) 评论(0) 推荐(0)
摘要: 1.欧几里得算法 求解最大公约数,时间复杂度在O(log max(a,b))以内,可以看出,辗转相除法是非常高效的 2.扩展欧几里得算法 求解方程a*x+b*y=gcd(a,b),a、b、x、y均为整数,时间复杂度和辗转相除法是相同的,函数返回gcd(a,b)。 3.素数测试 其中map第一个int 阅读全文
posted @ 2018-08-27 15:43 #忘乎所以# 阅读(161) 评论(0) 推荐(0)
摘要: Matrix Power Series Time Limit: 3000MS Memory Limit: 131072K Total Submissions:28021 Accepted: 11426 Description Given a n × n matrix A and a positive 阅读全文
posted @ 2018-08-27 11:15 #忘乎所以# 阅读(129) 评论(0) 推荐(0)
摘要: Problem Description 题目给出一个有n个节点的有向图,求该有向图中长度为k的路径条数。方便起见,节点编号为1,2,…,n,用邻接矩阵表示该有向图。该有向图的节点数不少于2并且不超过500. 例如包含两个节点的有向图,图中有两条边1 → 2 ,2 → 1 。 长度为1的路径有两条:1 阅读全文
posted @ 2018-08-27 09:34 #忘乎所以# 阅读(1629) 评论(0) 推荐(0)
摘要: 1242 斐波那契数列的第N项 基准时间限制:1 秒 空间限制:131072 KB 分值: 0 难度:基础题 1242 斐波那契数列的第N项 基准时间限制:1 秒 空间限制:131072 KB 分值: 0 难度:基础题 1242 斐波那契数列的第N项 基准时间限制:1 秒 空间限制:131072 K 阅读全文
posted @ 2018-08-26 14:12 #忘乎所以# 阅读(192) 评论(0) 推荐(0)
摘要: Pseudoprime numbers Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 3408 Accepted Submission(s): 阅读全文
posted @ 2018-08-24 21:28 #忘乎所以# 阅读(109) 评论(0) 推荐(0)
摘要: Cutting Game Time Limit: 1000MS Memory Limit: 65536K Total Submissions:5544 Accepted: 2022 Description Urej loves to play various types of dull games. 阅读全文
posted @ 2018-08-23 21:38 #忘乎所以# 阅读(154) 评论(0) 推荐(0)
摘要: Cleaning Shifts Time Limit: 1000MS Memory Limit: 65536K Total Submissions:31249 Accepted: 7684 Description Farmer John is assigning some of his N (1 < 阅读全文
posted @ 2018-08-20 21:22 #忘乎所以# 阅读(451) 评论(0) 推荐(0)
摘要: A. Palindromic Twist time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output A. Palindromic Twis 阅读全文
posted @ 2018-08-19 15:45 #忘乎所以# 阅读(319) 评论(0) 推荐(0)
摘要: deque(包含头文件#include<deque>)由若干段连续空间串接而成,一旦有必要在deque的头部或尾端增加新的空间,便配置一段定量连续的空间,串接在deque的头部或尾端。deque的最大任务,就是在这些分段连续的空间上维护其整体连续的假象,并提供随机存取的接口。 实际上。deque内部 阅读全文
posted @ 2018-08-11 22:22 #忘乎所以# 阅读(364) 评论(0) 推荐(0)
上一页 1 ··· 12 13 14 15 16 17 18 19 20 ··· 39 下一页