Codeforce
Ziwen.紫闻
这个作者很懒,什么都没留下…
展开
-
Codeforce 1059A. Cashier
A. Cashier time limit per test2 seconds memory limit per test256 megabytes inputstandard input outputstandard output Vasya has recently got a job as a cashier at a local store. His day at work is L minutes long. Vasya has already memorized n regular cu原创 2018-10-07 13:27:45 · 368 阅读 · 0 评论 -
Codeforce 1059B Forgery
给出一个老师的字迹,问能不能用一个3*3,中间空心的印章,印出老师的字迹。 要求:印章不能印出外边。 http://codeforces.com/contest/1059/problem/B 逆向思维,每一个空心的都不能在四周盖章。扫描一遍后,再扫描墨水印,如果存在一个墨水印是不能印出来的,则返回NO,否则返回YES #include<iostream> #incl...原创 2018-10-07 14:12:05 · 241 阅读 · 0 评论 -
CodeForce 1111A 2019/2/4
http://codeforces.com/contest/1111/problem/A S,T序列 长度不同,否。 长度相同,若每个对应字母,都是元音或者都是辅音,对。 #include<bits/stdc++.h> using namespace std; long long a[200060]; long long n,m; char ch[]={'a','e','...原创 2019-02-04 01:24:17 · 151 阅读 · 0 评论 -
Codeforces 1111B 2019/2/4
给你个复仇者联盟能量值。 你可以进行如下操作 ①删去一个数 ②给任意值+1,但是每个数最多可以加k次 注意::特判n==1的情况,wa*3 #include<bits/stdc++.h> using namespace std; long long a[200060]; long long sum[200060]; long long n,k,m,s=0; char ch[]...原创 2019-02-04 01:29:28 · 300 阅读 · 0 评论 -
Codeforces 1107 2019/2/4
http://codeforces.com/contest/1107/problem/A A题,水题,给出一串序列,让你任意分割成任意段,要求每段都要递增。 题解:只需要切割成两段就行了。 坑点:字符串的最后一位是n-1,还有就是要看题,题目要求写出分割了多少段,for(int i=1;i<n;i++) for(int i=1;i<=n;i++) wa*3 学习:S.subs...原创 2019-02-04 12:20:31 · 265 阅读 · 0 评论 -
CF 1110 2019/2/8
A题 求方程的解是偶数还是奇数。 #include<bits/stdc++.h> using namespace std; #define ll long long long long a[1000000]; bool check_even(ll num,ll b,ll k) { if(k==0) { if(num%2==0) { return true; ...原创 2019-02-08 10:22:02 · 279 阅读 · 0 评论 -
1041C 2019/2/8 数据结构set
坑的一比,自己超级沙雕。 #include<iostream> #include<algorithm> #include<set> #define ll int using namespace std; struct ss{ ll x; ll index_; }a[300050]; ll flag[300050]; set<ll> st; l...原创 2019-02-08 16:03:41 · 116 阅读 · 0 评论 -
cf 1105 2019/2/10
mod3 dp Biu—— 好题 #include<bits/stdc++.h> using namespace std; #define ll long long ll f[200050][6]; ll mod=1e9+7; int main() { int n,l,r; cin>>n>>l>>r; ll mod0=r/3-(l-1...原创 2019-02-10 11:21:19 · 174 阅读 · 0 评论