AtCoder Beginner Contest 359 A - Count Takahashi (abc359 A) 题目大意 给定nn个字符串,问有多少个字符串是Takahashi 解题思路 注意判断比较即可。 神奇的代码 #include<bits/stdc++.h> usingnamespacestd; usingLL =longlong; intmain(void){ ios::sync_with_stdio(false); cin.tie(0); cout.tie(0)...
AtCoder Beginner Contest 359 A~F https://www.bilibili.com/video/BV1G4gveBENB/ AtCoder Beginner Contest 359 | 完成度 [6 / 7] https://www.bilibili.com/video/BV1kS411A7M3/ AtCoder Beginner Contest 359 A 至 G 題讲解 by dreamoon https://www.bilibili.com/video/BV1x1421r7gH/ AtCoder...
https://atcoder.jp/contests/abc359/tasks A - Count Takahashi voidsolve(){intn; cin >> n;intans =0;while(n --){strings; cin >> s;if(s =="Takahashi"){ ans ++; } } cout << ans << endl; } B - Couples void solve() { int n; cin >> n; vector<int>a(2* n);for(aut...
AtCoder Beginner Contest 267 F(树的直径/树上倍增) 严格鸽 Atcoder Beginner Contest 400 题解(A~D) 热爱算法的小弱鸡又来写题啦~~,可否施舍一个关注给俺呢~A - ABC400 Party这个题目很简单,矩形总面积是400,给出一条边,如果存在另一条边,输出边长,否则输出 -1 #include<bits/stdc+… 君缘发表...
判断图中存在闭环的常用方法——以Atcoder Beginner Contest 285(D - Change Usernames)为例 656 2 24:27 App AtCoder Beginner Contest 370(A ~ F 题讲解) 472 1 06:29 App AtCoder Beginner Contest 354(G 题讲解) 466 1 47:47 App AtCoder Beginner Contest 388(A ~ G 题讲解) 502 0 22:37 ...
Code #include<bits/stdc++.h>usingnamespacestd;intmain(){ios::sync_with_stdio(false);intN;cin>>N;vector<vector<int>>p(N,vector<int>());for(inti=1;i<=2*N;i++){intcol;cin>>col;p[col-1].push_back(i);}intcnt=0;for(autov:p){if(abs(v[0]-v[1])==2)cnt+=1;}cout<<...
·AtCoder Beginner Contest (ABC) 这是最频繁且最简单的入门赛,通常情况下每月至少举行2次。2019年4月27日(含)之前,每场比赛共4题,时长100分钟,满分1000分且Rating超过1199的选手不计Rating值。自2019年5月19日起改版升级为6道题目,时长不变,满分2100分且Rating值超过1999的选手不计Rating值。改版之后比赛质量...
We will hold AtCoder Beginner Contest 395. Contest URL:https://atcoder.jp/contests/abc395 Start Time:http://www.timeanddate.com/worldclock/fixedtime.html?iso=20250301T2100&p1=248 Duration: 100 minutes Writer:hirayuu_cf, MMNMM,ynymxiaolongbao ...
We will hold AtCoder Beginner Contest 395. Contest URL: https://atcoder.jp/contests/abc395 Start Time: http://www.timeanddate.com/worldclock/fixedtime.html?iso=20250301T2100&p1=248 Duration: 100 minutes Writer: hirayuu_cf, MMNMM, ynymxiaolongbao Tester: Nyaan, kyopro_friends Rated ...
AtCoder Beginner Contest 193 部分题解 E - Oversleeping 求是否存在\(t\)满足\(t=t_1(mod (2X+2Y)) and t=t_2(mod (P+Q))\) 注意到\(Q\)和\(Y\)非常小,直接枚举套个\(exCRT\)就行了(虽然赛场上没看出来,\(exCRT\)也忘了记得快速乘...