摘要:题目链接:http://codeforces.com/contest/828/problem/E E. DNA Evolution time limit per test 2 seconds memory limit per test 512 megabytes input standard inp
阅读全文
摘要:题目链接:http://codeforces.com/contest/828/problem/C C. String Reconstruction time limit per test 2 seconds memory limit per test 256 megabytes input stan
阅读全文
摘要:题目链接:http://codeforces.com/contest/828 A. Restaurant Tables time limit per test 1 second memory limit per test 256 megabytes input standard input outp
阅读全文
摘要:题目链接:http://codeforces.com/contest/937 B. Vile Grasshoppers time limit per test 1 second memory limit per test 256 megabytes input standard input outp
阅读全文
摘要:题目链接:https://vjudge.net/problem/HDU-3336 Count the string Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submis
阅读全文
摘要:题目链接:https://vjudge.net/problem/CodeForces-960F You are given a directed graph with n nodes and m edges, with all edges having a certain weight. There
阅读全文
摘要:题目链接:http://www.51nod.com/onlineJudge/questionCode.html#!problemId=1627 1627 瞬间移动 基准时间限制:1 秒 空间限制:131072 KB 分值: 80 难度:5级算法题 收藏 关注 1627 瞬间移动 基准时间限制:1 秒
阅读全文
摘要:题目链接:http://www.51nod.com/onlineJudge/questionCode.html#!problemId=1158 1158 全是1的最大子矩阵 基准时间限制:1 秒 空间限制:131072 KB 分值: 80 难度:5级算法题 收藏 关注 1158 全是1的最大子矩阵
阅读全文
摘要:题目链接:http://www.51nod.com/onlineJudge/questionCode.html#!problemId=1225 1225 余数之和 基准时间限制:1 秒 空间限制:131072 KB 分值: 80 难度:5级算法题 收藏 关注 1225 余数之和 基准时间限制:1 秒
阅读全文
摘要:题目链接:http://www.51nod.com/onlineJudge/questionCode.html#!problemId=1084 1084 矩阵取数问题 V2 基准时间限制:2 秒 空间限制:131072 KB 分值: 80 难度:5级算法题 收藏 关注 1084 矩阵取数问题 V2
阅读全文
摘要:题目链接:http://www.51nod.com/onlineJudge/questionCode.html#!problemId=1120 题解: 1.看到这种题,马上就想到了卡特兰数。但卡特兰数最快也要O(n)的时间复杂度去递推或者预处理,而n的范围是1e9,所以行不通。但发现Mod的值为10
阅读全文
摘要:题目链接:http://www.51nod.com/onlineJudge/questionCode.html#!problemId=1295 1295 XOR key 题目来源: HackerRank 基准时间限制:1.5 秒 空间限制:262144 KB 分值: 160 难度:6级算法题 收藏
阅读全文
摘要:题目链接:https://vjudge.net/problem/HDU-4825 Xor Sum Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 132768/132768 K (Java/Others)Total Submission(s)
阅读全文
摘要:题目链接:http://www.51nod.com/onlineJudge/questionCode.html#!problemId=1515 1515 明辨是非 题目来源: 原创 基准时间限制:1 秒 空间限制:131072 KB 分值: 160 难度:6级算法题 收藏 关注 1515 明辨是非
阅读全文
摘要:题目链接:http://www.51nod.com/onlineJudge/questionCode.html#!problemId=1376 1376 最长递增子序列的数量 基准时间限制:1 秒 空间限制:131072 KB 分值: 160 难度:6级算法题 收藏 关注 数组A包含N个整数(可能包
阅读全文
摘要:题目链接:https://vjudge.net/problem/UVA-11426 题意: 求 ∑ gcd(i,j),其中 1<=i<j<=n 。 题解:1. 欧拉函数的定义:满足 0<x<n 且 gcd(x,n) = 1 的x有euler[n]个。 2. 可以推论出:满足 0<2*x<2*n 且
阅读全文
摘要:题目链接:http://poj.org/problem?id=2104 K-th Number Time Limit: 20000MS Memory Limit: 65536K Total Submissions: 64277 Accepted: 22615 Case Time Limit: 200
阅读全文
摘要:题目链接:http://www.51nod.com/onlineJudge/questionCode.html#!problemId=1294 1294 修改数组 题目来源: HackerRank 基准时间限制:1 秒 空间限制:131072 KB 分值: 160 难度:6级算法题 收藏 关注 12
阅读全文
摘要:题目链接:http://www.51nod.com/onlineJudge/questionCode.html#!problemId=1022 1022 石子归并 V2 基准时间限制:1 秒 空间限制:131072 KB 分值: 160 难度:6级算法题 收藏 关注 N堆石子摆成一个环。现要将石子有
阅读全文
摘要:题目链接:https://vjudge.net/problem/51Nod-1486 1486 大大走格子 题目来源: CodeForces 基准时间限制:1 秒 空间限制:131072 KB 分值: 160 难度:6级算法题 1486 大大走格子 题目来源: CodeForces 基准时间限制:1
阅读全文