![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
乱搞
mengwuyaaa
这个作者很懒,什么都没留下…
展开
-
CF 777C
题意:给出一个n*m<100000的矩阵,给出k个查询,每个查询给出l,r两个数字,问在l行与r行之间是否存在一列拥有非递减序。题解:用vector存每个位置的起始位置。用数组存每行的起始位置的最小值。查询复杂度O(1)。#include<iostream>#include<vector>using namespace std;const int INF=1e...原创 2018-04-13 00:53:19 · 1179 阅读 · 0 评论 -
CF 735D
题意:国际象棋规则,看黑方是否被将军题解:八个方向上把最近的点都记下来看看能不能凑合,有一个能凑合就可以输出YES,不然GG#include<iostream>#include<cmath>using namespace std;const long long INF=1e10+1;struct S{ char ch; long long x,y...原创 2018-04-16 21:51:24 · 789 阅读 · 0 评论 -
CF 519D
题目:找出字符串中权值和为0且首位字母相同的子串个数题解:计算前缀和。#include<iostream>#include<string>#include<map>using namespace std;long long alpha[26];string str;int main(){ for(long long i=0;i<26...原创 2018-05-16 22:52:01 · 230 阅读 · 0 评论 -
CF 742C
题目:今天心情不好不写题目题解:仔细想想还是好生气啊!烦躁烦躁……偶数/2,奇数直接LCM。#include<iostream>#include<cstring>using namespace std;int gcd(int a,int b){ if(b==0) return a; return gcd(b,a%b);}int lcm(int ...原创 2018-04-26 13:56:54 · 183 阅读 · 0 评论 -
CF 701C
题目:滑动队列题解:水题秒做系列。。#include<iostream>#include<string>#include<map>using namespace std;string str;map<char,int> mmm;int main(){ int len; int cnt=0; cin>>...原创 2018-05-04 19:45:51 · 142 阅读 · 0 评论 -
CF 519C
题目:水题不翻题解:for循环c语言练习题#include<iostream>#include<algorithm>using namespace std;int main(){ int n,m; cin>>n>>m; int maxx=-1e9-1; for(int i=0;i<=n;i++){ ...原创 2018-05-16 21:35:33 · 570 阅读 · 0 评论