题解complete compress atcoder

AT2271 [ARC066A] Lining Up 题解

## 题目大意 有 $n$ 个人排成一列,每个人左边的人数减去右边的人数的绝对值已经固定,问有几种排列情况(如果报告错误,输出 $0$)。 ## 思路 ### 找规律 举一个例子,当 $n=5$ 的时候,从左到右他们的 $A_{i}$ 就分别为 $4$ $2$ $0$ $2$ $4$ ; 当 $n= ......
题解 Lining 2271 066A 066

SP15637 Mr Youngs Picture Permutations 题解

## 题意 给定一个最多有 $5$ 排的一个队伍,每一个位置对应一个同学,给定总人数和第 $i$ 排 要站 $n_i$ 个人。 要求每行左边的同学身高要大于右边的,每列从上往下要从大到小。 问:满足要求的一共有多少种方案。 ## 思路 ### DP - 首先考虑,在这个题目中,有用的状态有**每列最 ......
题解 Permutations Picture Youngs 15637

P7284 [COCI2020-2021#4] Patkice II 题解

广搜好题 ## 题目大意 起点是 "o" , 终点是 "x" ,"^ v " 表示四种洋流,鸭子进入洋流后就可以沿着该方向移动距离, "." 是平静的海面,鸭子进入这里就会停止。问我们需要至少改变多少个字符才能使鸭子从起点走向终点,并且打印出改变字符后的地图。 ## 思路 一般求最短路径的算法就是 ......
题解 Patkice P7284 7284 2020

P2480 古代猪文 题解

题意:求 $$ g^{\sum_{k\mid n}{n\choose k}} $$ 对 $999911659$ 取模。 $1\le n,g\le 10^9$。 思路: 首先根据欧拉定理,题目转化为求 $\displaystyle\sum_{k\mid n}{n\choose k}$ 对 $99991 ......
题解 P2480 2480

JOISC 2021 题解

#### JOISC21 フードコート (Food Court) 首先我们发现我们这个删除实际上可以假删除,我们每次问询时求出这个队列目前被删了几个(维护区间加,区间 $\max(0,A-x)$)就可以把删除操作给弄掉了。 然后我们考虑对商店做扫描线!因为我们现在其实就是对商店的单点问询,我们这个加 ......
题解 JOISC 2021

【题解】Codeforces Round 737 (CF1557)

VP 情况: solve:4/5 rank:431st 评价: VP 了一下,我这个 shaber B 直接 5 发罚时,耽误了二十多分钟,以及被 D 各种细节差点搞死。 ## A.Ezzat and Two Subsequences(*800) ### 题目描述: 给定一个序列,将其分为 $2$ ......
题解 Codeforces Round 1557 737

AtCoder Beginner Contest 302

# A - Attack ```cpp #include using namespace std; #define int long long int32_t main() { int a , b; cin >> a >> b; cout using namespace std; #define i ......
Beginner AtCoder Contest 302

AtCoder Regular Contest 146 D >=<

[洛谷传送门](https://www.luogu.com.cn/problem/AT_arc146_d "洛谷传送门") [AtCoder 传送门](https://atcoder.jp/contests/arc146/tasks/arc146_d "AtCoder 传送门") 考虑直接增量构造。 ......
AtCoder Regular Contest 146 gt

【题解】CF1062E Company

[传送门](https://www.luogu.com.cn/problem/CF1062E) 先考虑如何求解区间 LCA ![](https://img2023.cnblogs.com/blog/2751294/202305/2751294-20230525152449076-352315544. ......
题解 Company 1062E 1062 CF

B. Complete The Graph

B. Complete The Graph ZS the Coder has drawn an undirected graph of $n$ vertices numbered from $0$ to $n - 1$ and $m$ edges between them. Each edge of ......
Complete Graph The

AtCoder Beginner Contest 193 F Zebraness

[洛谷传送门](https://www.luogu.com.cn/problem/AT_abc193_f "洛谷传送门") [AtCoder 传送门](https://atcoder.jp/contests/abc193/tasks/abc193_f "AtCoder 传送门") 复习一下最小割。 ......
Zebraness Beginner AtCoder Contest 193

题解(教主的魔法)P2801

## [题目](https://www.luogu.com.cn/problem/P2801) # 教主的魔法 ## 题目描述 教主最近学会了一种神奇的魔法,能够使人长高。于是他准备演示给 XMYZ 信息组每个英雄看。于是 $N$ 个英雄们又一次聚集在了一起,这次他们排成了一列,被编号为 $1, 2 ......
题解 教主 魔法 P2801 2801

ORA-15032 ORA-15250 insufficient diskgroup space for rebalance completion

Oracle集群环境更换存储时提示 ora-15032:not all alterations performed ora-15250:insufficient diskgroup space for rebalance completion 几经折腾发现是由于两个存储之间计算方式不一致,导致新盘比 ......

AtCoder Regular Contest 146 C Even XOR

[洛谷传送门](https://www.luogu.com.cn/problem/AT_arc146_c "洛谷传送门") [AtCoder 传送门](https://atcoder.jp/contests/arc146/tasks/arc146_c "AtCoder 传送门") 好可爱的题啊。 没 ......
AtCoder Regular Contest Even 146

AtCoder Beginner Contest 302 H. Ball Collector 题解

[AtCoder Beginner Contest 302 H. Ball Collector](https://atcoder.jp/contests/abc302/tasks/abc302_h) 题意跳过。 可以视作将 $a_i, b_i$ 之间连了一条边,然后 $a_i, b_i$ 之间只能选 ......
题解 Collector Beginner AtCoder Contest

CF1819C The Fox and the Complete Tree Traversal

# [$\color{purple}\text{The Fox and the Complete Tree Traversal}$](https://www.luogu.com.cn/problem/CF1819C) 比较有意思的一题。先考虑一个序列的权值。对长度为 $len$ 的序列排序,价值为 ......
Traversal Complete 1819C 1819 Tree

AtCoder Beginner Contest 267 Ex Odd Sum

[洛谷传送门](https://www.luogu.com.cn/problem/AT_abc267_h "洛谷传送门") [AtCoder 传送门](https://atcoder.jp/contests/abc267/tasks/abc267_h "AtCoder 传送门") 直接暴力跑背包的复 ......
Beginner AtCoder Contest 267 Odd

AtCoder Beginner Contest 302(E,F,G)

# AtCoder Beginner Contest 302(E,F,G) ## E(图,set) [E](https://atcoder.jp/contests/abc302/tasks/abc302_e) 这个题意大致为一开始给出$n$个点,没有一条边,后面陆续会有$q$次操作,以下两种方式 $ ......
Beginner AtCoder Contest 302

NOIP2014普及组试题题解

1.珠心算测验 代码: #include<bits/stdc++.h> #define ll long long using namespace std; const int N = 2e4+39+7; int mp[N],n,a[N],ans=0; int main(){ cin>>n; for( ......
题解 试题 NOIP 2014

AtCoder Regular Contest 139 D Priority Queue 2

[洛谷传送门](https://www.luogu.com.cn/problem/AT_arc139_d "洛谷传送门") [AtCoder 传送门](https://atcoder.jp/contests/arc139/tasks/arc139_d "AtCoder 传送门") 看成方案数想了 1 ......
Priority AtCoder Regular Contest Queue

题解:Code Feat

[题目链接](https://www.luogu.com.cn/problem/UVA11754) 数据范围分治。沿用题目中的变量意义。设 $K = \Pi k_i$,即我们总共有 $K$ 种组合情况,当 $K$ 比较小的时候,直接枚举每个集合得到的余数是哪个,然后做 CRT 记录后排序答案即可。当 ......
题解 Code Feat

abc260_f Find 4-cycle 题解

# [Find 4-cycle](https://vjudge.csgrandeur.cn/problem/AtCoder-abc260_f) ## 题意 有一个 $s + t$ 个点 $m$ 条边的简单无向图 $G$。点标号为 $1 \cdots s + t$,边标号为 $1 \cdots m$。 ......
题解 cycle Find abc 260

abc260_e At Least One 题解

# [At Least One](https://vjudge.csgrandeur.cn/problem/AtCoder-abc260_e) ## 题意 给定一个整数 $m$ 和 $n$ 对数 $(a_i, b_i)$,我们定义一个 $f(x)$ 函数表示满足以下要求的整数序列数量: - 整数序列 ......
题解 Least abc 260 One

abc273_e Notebook 题解

# [Notebook](https://vjudge.csgrandeur.cn/problem/AtCoder-abc273_e) ## 题意 有 $q$ 次操作。 现在你有一个空序列 $a$ 和一本 $10^9$ 页的笔记本,每页纸上都有一个空序列。 每次操作是以下四种中的一种: - `ADD ......
题解 Notebook abc 273

AtCoder Regular Contest 132 E Paw

[洛谷传送门](https://www.luogu.com.cn/problem/AT_arc132_e "洛谷传送门") [AtCoder 传送门](https://atcoder.jp/contests/arc132/tasks/arc132_e "AtCoder 传送门") 感觉挺 educa ......
AtCoder Regular Contest 132 Paw

Game on Paper 题解

[题目传送门](https://www.luogu.com.cn/problem/CF203B) 一道模拟题。 如果每涂一个格子就判断整个矩阵,那时间复杂度显然会炸。 我们每涂一个格子,影响的应该只是以这个格子为中心的 $3 \times 3$ 矩阵,判断以这些点为中心的话会不会涂出 $3 \tim ......
题解 Paper Game on

AtCoder Regular Contest 132 F Takahashi The Strongest

[洛谷传送门](https://www.luogu.com.cn/problem/AT_arc132_f "洛谷传送门") [AtCoder 传送门](https://atcoder.jp/contests/arc132/tasks/arc132_f "AtCoder 传送门") 没见过这种在新运算 ......
Takahashi Strongest AtCoder Regular Contest

1110 Complete Binary Tree(附测试点2,3,4,6分析)

题目: Given a tree, you are supposed to tell if it is a complete binary tree. Input Specification: Each input file contains one test case. For each case ......
Complete Binary 1110 Tree

2023(ICPC)江西省赛I题题解

I. Tree 题意: 两种操作,操作1:将一棵树一条路径上的边权异或上一个数,操作2:或者询问一个点周 围所有边权的异或和。 题解: 首先,异或有一个性质 A ⨁ A = 0 ⇒ A ⨁ B ⨁ A = B 在进行操作一时,对X到Y的简单路径上的每一条边权异或,会是这样的情况 X _ w1_ Z ......
题解 2023 ICPC

abc271_f XOR on Grid Path 题解

# [XOR on Grid Path](https://vjudge.csgrandeur.cn/problem/AtCoder-abc271_f) ## 题意 有一个 $n \times n$ 的整数矩阵,第 $i$ 行 $j$ 列的数字为 $a_{i,j}$。 你站在 $(1,1)$,每次你可 ......
题解 Grid Path abc 271