输入1-999就输出ABC,否则输出ABD #include<bits/stdc++.h>usingnamespacestd;constintN =1e6+5;typedeflonglongLL;intn;intmain(){cin>> n;if(n >=1000)cout<<"ABD"<<endl;elsecout<<"ABC"<<endl;return0;} B - Stone Monument 大意: 从左到右有999个塔,塔高分别为1 1+2 1+2+3 1+2+3+4...
1、今晚(5月17日)20点在B站开始 AtCoder 初学者竞赛 353 比赛题解直播讲解 2、本周日(5月19日)晚上19点在B站开始 AtCoder Beginner Contest 354的题解直播讲解 3、观看方式: 复制下方链接或直接扫描二维码,PC端建议使用chrome浏览器 https://live.bilibili.com/21371611?live_from=84002 或识别下方二维码查看:...
合集-Atcoder Beginner Contest 题解 AT_ABC406_E Popcount Sum 3 摘要:洛谷题目传送门 ATcoder题目链接 题目大意 给你正整数NN和KK。 求所有不超过NN且满足以下条件的正整数xx的 和(取模998244353998244353):xx的popcountpopcount恰好是KK。 给你TT阅读全文 posted @2025-05-18 20:57Cloudybunny...
We will hold AtCoder Beginner Contest 199(Sponsored by Panasonic). ,satashunYoshikaMiyafuji Rated range: ~ 1999 The point values will be 100-200-300-400-500-600. We are looking forward to your participation! If any of the vertices of a component have degree 3 or higher so our total answ...
\left| l_a - l_b \right| = 1并且\left| r_a - r_b \right| = 1。 r_a \ne l_a + 1并且r_b\ne l_b + 1。 那么就可以直接枚举相邻元素(a_{i - 1}, a_i)判断是否满足条件,注意去重。 #include<bits/stdc++.h>usingnamespacestd;usingLL=longlong;voidsolve(){intn;cin>>n;vec...
CMake it Forest DSwitch Seats CMake it Forest 贾恒:判断图中是否有环的三种方法 要求没有环,该图是无向图,若两点之间已经联通,再加边一定成环,使用并查集,对于每次读入的边,若这两条边已经在一个集合,则再加边就成环,所以ans++。 #include"bits/stdc++.h"#define ll long longusingnamespacestd;intn...
We will hold AtCoder Beginner Contest 396. Contest URL: https://atcoder.jp/contests/abc396 Start Time: http://www.timeanddate.com/worldclock/fixedtime.html?iso=20250308T2100&p1=248 Duration: 100 minutes Writer: toam, sounansya Tester: physics0523, yuto1115 Rated range: ~ 1999 The point...
判断图中存在闭环的常用方法——以Atcoder Beginner Contest 285(D - Change Usernames)为例 737 0 30:29 App AtCoder Beginner Contest 392(A ~ G 题讲解) 559 0 21:08 App Atcoder Beginner Contest 338 289 0 17:35 App Atcoder Beginner Contest 348(A ~ F 讲解,无 D) 1326 0 22:18 App ...
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...
AtCoder Beginner Contest 169(题解)E - Count Median结论题给定nnn个xi∈[ai,bi]x_i\in[a_i,b_i]xi∈[ai,bi],求中位数的个数。定义:k=⌊n2⌋k=\lfloor\dfrac{n}{2}\rfloork=⌊2n⌋,对a,ba,ba,b进行排序后,为ak+1a_{k+1}ak+1为aia_iai的中位数,bk+1...