Codeforces round #772 (Div. 2)

Source code: ACM/OpenjudgeNow/Codeforces at master · abmcar/ACM (github.com) Better reading experience: Jump coordinate A. Min Or Sum Main idea of the title: Idea: A + b > = a | B, we can replace a and B with 0,a|b. in this form, finally, we can replace the array with several zeros and an array | and The final sum is the array | an ...

Added by haydndup on Tue, 08 Mar 2022 05:08:28 +0200

Codeforces round #716 (Div. 2) d. cut and stick chairman tree + thinking

Portal Meaning: Here's a long for you n n Array of n a a a. The defined interval is the number of occurrences of each number in this interval ≤ ...

Added by cresler on Fri, 04 Mar 2022 01:02:34 +0200

2020 Jiangsu Collegiate Programming Contest-A.Array

Array Title Description Yukikaze received an array (a1,a2,⋯an)as a gift. She decided to play with it. The game consists of q turns. In each turn, she will perform some kind of operation (listed below) on all elements in a subarray of a. In this problem, we define that 00=1. Since the result of operations of the last two kinds may be large ...

Added by phpcat on Fri, 28 Jan 2022 20:55:53 +0200

Codeforces Round #768 (Div. 2) ideas sharing

Codeforces Round #768 (Div. 2) Stuck on D again After that, I jumped directly to do E and made a fake. I lost blood. Of course, I must have lost points again A. Min Max Swapr Consider that the largest number in a and b must be max. consider making the other number small. Then directly put the large number in the same position into one sequence ...

Added by JD-AM on Fri, 28 Jan 2022 18:39:43 +0200

[CFGym102586L] Yosupo's Algorithm

Title Link Given \ (n \) red points and \ (n \) blue points on the two-dimensional plane, each point has a point weight. \(q \) queries, each given \ (L,R \). It is required to find a red dot \ ((rx,ry) \) (weight value \ (rv \)) and a blue dot \ ((bx,by) \) (weight value \ (bv \)), which meet the following requirements: \ (ry < by \)\ (Rx ...

Added by mu-ziq on Wed, 26 Jan 2022 22:58:57 +0200

Codeforces 1547f array stabilization (GCD version)

Title Link: Array Stabilization (GCD version) General meaning Given an array of length n, the subscripts are from 1 to n. where an and a1 are connected (form a ring) Each round of operation yields a new array b: for all I ∈ [1, n], b[i] = gcd(a[i], a[i + 1]) (b[n] = gcd(a[n], a[1]) Finally, copy the new array b to the original array a ...

Added by john-iom on Wed, 19 Jan 2022 11:52:20 +0200

Codeforces Round #730 (Div. 2) problem solving + supplementary questions

A. Exciting Bets 1, Title Link https://codeforces.ml/contest/1543/problem/A 2, General idea of the topic There are t groups of data, and each group of data contains a pair of a and B. You can perform any number of operations. Each operation can add or subtract a and B at the same time. Let the last two numbers be x and y, and the title want ...

Added by billkom on Wed, 19 Jan 2022 07:42:54 +0200

Educational Codeforces Round 121 (Rated for Div. 2)

Current supplement to D A. Equidistant Letters Title Description: give you a string \ (s \), which only contains lowercase letters, and each letter does not appear more than \ (2 \) times. Let you rearrange \ (s \) so that the subscript difference of each pair of characters that appear twice is the same. Idea: sort \ (s \) so that the subscript ...

Added by daiwa on Mon, 17 Jan 2022 15:45:47 +0200

[cf1428H]Rotary Laser Lock

For convenience, the number of the initial left end point of the 0 interval is 0, and the other positions are $[1,nm) clockwise$ Consider rotating the 0 interval clockwise and record $s_{i} $is the answer when the left end point of the 0 interval is rotated to $I $(agreed $s {I + n} = s {I} $) Nature 1: if $s_{i}-s_{i-1}=1 $and $s_{i+1}-s_{i}\n ...

Added by alevsky on Sun, 16 Jan 2022 17:59:00 +0200

Codeforces Round #734 (Div. 3)

Hello, everyone, what I bring to you today is Codeforces Round #734 (Div. 3) Explain the whole topic. Link to this article: https://www.lanqiao.cn/questions/204012 Thank Lqyk students of blue bridge cloud class for their solutions. A. Polycarp and Coins Title Link https://codeforces.com/contest/1551/problem/A General idea of the topic ...

Added by MnM333 on Wed, 12 Jan 2022 09:50:43 +0200