https://www.gravatar.com/avatar/8f3abece0f8608ce4b9c1e3212fd1b72?s=240&d=mp

CF165D-Beard Graph

CF165D-Beard Graph 题目: 题目描述: Let’s define a non-oriented connected graph of $ n $ vertices and $ n-1 $ edges as a beard, if all of its vertices except, perhaps, one, have the degree of 2 or 1 (that is, there exists no more than one vertex, whose degree is more than two). Let us remind you that the degree of a vertex is

CF1045G-AI robots

CF1045G-AI robots 题目: 题目描述: In the last mission, MDCS has successfully shipped $ N $ AI robots to Mars. Before they start exploring, system initialization is required so they are arranged in a line. Every robot can be described with three numbers: position ( $ x_i $ ), radius of sight ( $ r_i $ ) and IQ ( $ q_i $ ). Since

CF1416C-XOR Inverse

CF1416C-XOR Inverse 题目: 题目描述: You are given an array $ a $ consisting of $ n $ non-negative integers. You have to choose a non-negative integer $ x $ and form a new array $ b $ of size $ n $ according to the following rule: for all $ i $ from $ 1 $ to $ n $ , $ b_i =

CF1416B-Make Them Equal

CF1416B-Make Them Equal 题目: 题目描述: You are given an array $ a $ consisting of $ n $ positive integers, numbered from $ 1 $ to $ n $ . You can perform the following operation no more than $ 3n $ times: choose three integers $ i $ , $ j $ and $ x $ ( $ 1 \le i, j \le

CF1416A-k-Amazing Numbers

CF1416A-k-Amazing Numbers 题目: 题目描述: You are given an array $ a $ consisting of $ n $ integers numbered from $ 1 $ to $ n $ . Let’s define the $ k $ -amazing number of the array as the minimum number that occurs in all of the subsegments of the array having length $ k $ (recall that a subsegment of $