#include<bits/stdc++.h> using namespace std; typedef long long ll; const int maxn=3e5+100; const int mod=998244353; ll fpow (int x,int y) { ll ans=1; ...
分类:
其他好文 时间:
2020-07-18 22:52:12
阅读次数:
105
A 根据性质,\(a,b,c\) 中的最大值一定会在 $x,y,z $ 中出现两次 #include <bits/stdc++.h> using namespace std; int main() { int t; cin >> t; int a[3]; while(t --) { memset(a ...
分类:
其他好文 时间:
2020-07-18 22:42:22
阅读次数:
86
#include<bits/stdc++.h> using namespace std; typedef long long ll; const int maxn=105; const int mod=1e9+7; int n; struct matrix { ll a[maxn][maxn]; m ...
分类:
其他好文 时间:
2020-07-18 22:14:26
阅读次数:
75
题目描述输入输出样例输入2 4 1 1 1 2 2 1 2 2 5 4 7 0 4 7 3 3 0 3 4样例输出Yes No提示n <= 1000000 T <= 10 0 <= x,y <= 10^9代码#include<bits/stdc++.h> using namespace std; c ...
分类:
其他好文 时间:
2020-07-18 16:06:57
阅读次数:
70
Three Pairwise Maximums #include<bits/stdc++.h> using namespace std; typedef long long ll; const int N=2e5+3; typedef long long ll; const ll inf=1e18; ...
分类:
其他好文 时间:
2020-07-18 11:29:01
阅读次数:
89
#include<bits/stdc++.h> using namespace std; typedef long long ll; const int N=5e5+10; struct node{ int cnt; node * nxt[27]; node * fail; vector<node ...
分类:
其他好文 时间:
2020-07-18 00:44:51
阅读次数:
57
题意:一段只包含'R,S,P'的字符串,希望你输出一段字符串使得无论起始位置 pos 在哪,你胜率最大的组合。 错误思路:分字符种类情况分析。(错误原因,只是找到单次比较最大值,但不是全局比较最大值) 正确思路:分字符数量情况分析。选最多的那个的对应字符。 #include <bits/stdc++ ...
分类:
其他好文 时间:
2020-07-17 22:20:17
阅读次数:
76
/* Name: Copyright: Author: Mudrobot Date: <DATETIME> Description: */ #include<bits/stdc++.h> #define gc() getchar()//caution!!! #define LL long long ...
分类:
其他好文 时间:
2020-07-17 14:04:00
阅读次数:
107
昨天突然脑袋比较清醒,好像似乎以前没有搞太懂的可持久化线段树一下子就搞懂了,结果打了几遍还是出现了一些意想不到的问题,下面我就来整理一下,防止以后重蹈覆辙! 下面我放一个50分的代码: #include<bits/stdc++.h> #define LL long long using namesp ...
分类:
其他好文 时间:
2020-07-17 13:57:31
阅读次数:
57
这道题我还有一些奇怪的地方没有搞懂,这里我先放一篇代码吧! 代码如下: #include<bits/stdc++.h> #define LL long long #define MX 4200 #define MOD 100000000 using namespace std; LL dp[13][ ...
分类:
其他好文 时间:
2020-07-17 13:54:28
阅读次数:
67