#include<vector>#include<iostream>#include<algorithm>usingi64 =longlong;usingvint = std::vector<int>;usingPII = std::pair<int,int>;intmain(void){//Think twice, code once.std::ios::sync_with_stdio(false); i64 a[3]; std::cin >> a[0] >> a[1] >> a[2]; i64 x = a[0] ...
We will hold AtCoder Regular Contest 155. Contest URL: https://atcoder.jp/contests/arc155 Start Time: http://www.timeanddate.com/worldclock/fixedtime.html?iso=20230129T2100&p1=248 Duration: 120 minutes Number of Tasks: 6 Writer: chinerist Tester: tatyam, satashun Rated range: — 2799 ...
F:每个长度为$len$的串出现的概率是相同的,求到长度为$len$的方案数然后除$2^{len}$。 ARC 060 D:对$b$分大于根号和小于根号讨论。 E:倍增预处理一个点往右跳$2^i$步后到哪里。 F:$KMP$找循环节。 ARC 061 D:开个$map$直接搞。 E:拆点最短路。 F:组合计数好题。 ARC 062 D:显然交错出是...
观察性质暴力 #include<bits/stdc++.h> usingnamespacestd; #definepb push_back #defineendl'\n' #defineLL long long constintN =5e5+10; intn, a[N], l[N], r[N]; LL pre[N], suf[N], b[N]; voidsolve(){ cin >> n; for(inti =1; i <= n; i++) { cin >> a[i]; b[i...
We will hold AtCoder Regular Contest 151. Contest URL:https://atcoder.jp/contests/arc151 Start Time:http://www.timeanddate.com/worldclock/fixedtime.html?iso=20221016T2100&p1=248 Duration: 120 minutes Number of Tasks: 6 Writer:leaf1415 ...
164 -- 1:43:11 App [6/8] AtCoder Beginner Contest 286 (unrated) 181 -- 27:25 App [6/6] VP AtCoder Beginner Contest 166 (随机 VP) 441 1 2:00:59 App [5/7] Educational Codeforces Round 142 (1660 ⭜ 1889) 468 -- 42:43 App AtCoder Beginner Contest 334 A 至 G 題...
AtCoder Beginner Contest 399(C-F详细题解) C 思路:作为一个简单无向图,有 n 个点只能有 n-1 条边,那我们只需要统计不同连通图上的点计算出所需的边即可,最后就是总边数减去所需的边即可。 代码:vector<vector<int>>… 秋日薄雾 AtCoder Beginner Contest 401 A-G 简易题解,如果题解...
如题,ARC150 A题 C题 的解题报告。 A - Continuous 1 题意: 有1, 0, ? 组成的一个序列(?可以为0/1), 问恰好有且仅有k个i, 且连续的情况有多少种。 分析: 考虑O(n). 常见为转化成求以每个 i 结尾的信息。 即求长度为k的序列满足以下条件的有且仅有一个: ...
AtCoder Regular Contest 090 C - Candies 链接:https://arc090.contest.atcoder.jp/tasks/arc090_a 题意:求矩形左上角到右下角的最大元素和(走动路径只能是向右或者向下) 分析:dfs,也可以是dp 【dfs】代码: #include <bits/stdc++.h> using namespace std;...
AtCoder Regular Contest 144(简称ARC 144)是AtCoder举办的一场定期比赛,旨在提供一个平台供程序员们展示他们的编程技能和解决问题的能力。本文将详细解析ARC 144的题目,并提供相应的解题思路和方法。 正文内容: 1.第一大点:题目一解析 1.1小点:题目背景介绍 在这里,我们将介绍题目的背景信息,包括题目的出处和相关...