brain

tamnd's digital brain — notes, problems, research

43815 notes

CF 1470B - Strange Definition

We are given an array of integers. Define two values as adjacent when $$frac{operatorname{lcm}(x,y)}{gcd(x,y)}$$ is a perfect square. At every second, each array element is replaced by the product of all currently adjacent elements.

codeforcescompetitive-programmingbitmasksgraphshashingmathnumber-theory
CF 1470C - Strange Shuffle

We have a circle of $n$ players, each holding $k$ cards. Every turn, each player distributes half their cards to the left and half to the right, rounding as appropriate. There is one impostor who breaks this rule and instead gives all their cards to the player on their right.

codeforcescompetitive-programmingbinary-searchbrute-forceconstructive-algorithmsinteractive
CF 1470A - Strange Birthday Party

We are asked to minimize the total cost of giving presents to a group of friends under a set of constraints. Each friend has a preferred present number, $ki$. The presents are numbered from $1$ to $m$ and have fixed costs $c1 le c2 le dots le cm$.

codeforcescompetitive-programmingbinary-searchdpgreedysortingstwo-pointers
CF 1471A - Strange Partition

We are given a sequence of positive integers, and we are allowed to repeatedly merge any two adjacent elements by replacing them with their sum. Every merge shortens the sequence by one element, but the total sum of all original values is preserved.

codeforcescompetitive-programminggreedymathnumber-theory
CF 1471B - Strange List

The process described in this problem is easier to understand if we think of the array as something that keeps expanding while being scanned from left to right. Every time we pick an element, we either expand it into smaller pieces or stop everything immediately.

codeforcescompetitive-programmingbrute-forcegreedyimplementationmath
CF 1472G - Moving to the Capital

We are given a directed graph whose vertices are cities and whose root is city 1, the capital. For every city $v$, define $d[v]$ as the shortest path length from city 1 to $v$. These distances are fixed and known implicitly from the graph. Polycarp starts from some city $s$.

codeforcescompetitive-programmingdfs-and-similardpgraphsshortest-paths
CF 1472E - Correct Placement

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingbinary-searchdata-structuresdpsortingstwo-pointers
CF 1472F - New Year's Puzzle

We are given a strip of size 2 by n, representing two rows of cells. Some cells are blocked and cannot be used. Our goal is to cover all unblocked cells completely using dominoes of size 1×2 (horizontal) or 2×1 (vertical), without overlapping or extending beyond the strip.

codeforcescompetitive-programmingbrute-forcedpgraph-matchingsgreedysortings
CF 1472B - Fair Division

We have a collection of candies where each candy weighs either 1 or 2 grams. Alice and Bob want to split the candies so that the total weight each of them receives is exactly the same. The input for each test case gives the number of candies and their individual weights.

codeforcescompetitive-programmingdpgreedymath
CF 1472D - Even-Odd Game

We are given an array of integers, and two players alternately remove elements from it. Alice starts first. Every time a player removes a number, only certain values actually contribute to their score: Alice gains points only from even numbers she picks, while Bob gains points…

codeforcescompetitive-programmingdpgamesgreedysortings
CF 1472C - Long Jumps

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingdpgraphs
CF 1472A - Cards for Friends

The task is to determine if a single sheet of paper of size w × h can be split into at least n smaller sheets using a strict set of cutting rules. Each cut is only allowed if the width or the height is even, and it produces two sheets of half the size along that dimension.

codeforcescompetitive-programminggreedymath
CF 1473G - Tiles

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingcombinatoricsdpfftmath
CF 1473F - Strange Set

We are selecting a subset of indices from an array of size $n$, and each index has a value $bi$ that contributes to a total score. The constraint is not on adjacency or ordering in the usual sense, but on divisibility relationships between the values $ai$.

codeforcescompetitive-programmingflowsmath
CF 1473A - Replacing Elements

We are given an array of positive integers and a threshold value, $d$. In one operation, we can pick any element and replace it with the sum of any two other distinct elements.

codeforcescompetitive-programminggreedyimplementationmathsortings
CF 1473E - Minimum Path

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programminggraphsshortest-paths
CF 1473D - Program

We are given a program that manipulates a single integer variable x, starting from 0. Each instruction either increments or decrements x by 1.

codeforcescompetitive-programmingdata-structuresdpimplementationstrings
CF 1473B - String LCM

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingbrute-forcemathnumber-theorystrings
CF 1473C - No More Inversions

We start with a fixed base array that goes up from 1 to k and then comes back down in a truncated way so that its length becomes n. This shape is a single peak: it strictly increases to k, then strictly decreases.

codeforcescompetitive-programmingconstructive-algorithmsmath
CF 1474F - 1 2 3 4 ...

We are given a starting integer $x$ and a sequence of integers $d1, d2, dots, dn$. From these, we generate a new sequence $p$ by repeatedly adding or subtracting 1 from the last element, depending on the sign of $di$, and repeating this $ Because each $di$ can be as large as…

codeforcescompetitive-programmingdpmathmatrices
CF 1474E - What Is It?

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingconstructive-algorithmsgreedy
CF 1474C - Array Destruction

We are given an array of 2n positive integers, and our goal is to remove all elements by repeatedly selecting pairs whose sum equals a current number x. Initially, we can choose any positive integer x equal to the sum of two numbers in the array.

codeforcescompetitive-programmingbrute-forceconstructive-algorithmsdata-structuresgreedyimplementationsortings
CF 1474D - Cleaning

We are given a line of stone piles, each pile containing some number of stones. The only allowed action removes stones in pairs: we pick two adjacent piles and delete one stone from each, as long as both piles are non-empty.

codeforcescompetitive-programmingdata-structuresdpgreedymath
CF 1474B - Different Divisors

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingbinary-searchconstructive-algorithmsgreedymathnumber-theory
CF 1474A - Puzzle From the Future

We are asked to construct a binary number a given another binary number b of the same length n in such a way that a derived number d is maximized. The process to obtain d is two-step. First, we compute c as the digit-wise sum of a and b without carrying.

codeforcescompetitive-programminggreedy
CF 1475F - Unusual Matrix

We are given two square binary matrices of the same size, called a and b. Each element is either 0 or 1. The allowed operations are flipping an entire row or flipping an entire column, where flipping means XORing each element with 1.

codeforcescompetitive-programming2-satbrute-forceconstructive-algorithms
CF 1475G - Strange Beauty

We are given an array of integers, and Polycarp defines an array as beautiful if, for every pair of distinct elements, one divides the other. In other words, for all $i ne j$, either $ai$ divides $aj$ or $aj$ divides $ai$.

codeforcescompetitive-programmingdpmathnumber-theorysortings
CF 1475E - Advertising Agency

Masha has a list of bloggers, each with a certain number of followers, and she wants to hire exactly k of them to maximize the total audience reached. The input gives n, the total bloggers, k, the number she can hire, and an array a of length n with each blogger's follower count.

codeforcescompetitive-programmingcombinatoricsmathsortings
CF 1475B - New Year's Number

We are given a number $n$, and we want to know whether it can be built by adding together some number of 2020s and some number of 2021s.

codeforcescompetitive-programmingbrute-forcedpmath
CF 1475D - Cleaning the Phone

We are given a phone with a list of installed apps. Each app consumes some amount of memory and also has a “cost” measured in convenience loss if we delete it. Every app contributes either 1 or 2 convenience points.

codeforcescompetitive-programmingbinary-searchdpsortingstwo-pointers
CF 1475C - Ball in Berland

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingcombinatoricsgraphsmath
CF 1475A - Odd Divisor

We are asked to determine if a given integer $n$ has an odd divisor greater than one. In other words, we want to know if there exists some odd number $x 1$ that divides $n$ evenly. If $n$ is divisible by such a number, the answer is "YES"; otherwise, it is "NO".

codeforcescompetitive-programmingmathnumber-theory
CF 1476F - Lanterns

We are given a row of lanterns, each with a power that determines how many consecutive lanterns it can illuminate in either direction. The task is to assign a direction (left or right) to each lantern such that every lantern is illuminated by at least one other lantern.

codeforcescompetitive-programmingbinary-searchdata-structuresdp
CF 1476G - Minimum Difference

We are working with an array of integers where we need to handle two types of operations efficiently. The first operation asks, for a given subarray, to select exactly k distinct numbers whose frequencies are as balanced as possible, minimizing the largest difference between…

codeforcescompetitive-programmingdata-structureshashingsortingstwo-pointers
CF 1476E - Pattern Matching

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingbitmasksdata-structuresdfs-and-similargraphshashingsortingsstrings
CF 1476D - Journey

We are given a chain of cities numbered from 0 to $n$, connected linearly by $n$ roads. Each road has a direction, either left (from city $i$ to $i-1$) or right (from $i-1$ to $i$). A traveler wants to start from some city and visit as many distinct cities as possible.

codeforcescompetitive-programmingdfs-and-similardpdsuimplementation
CF 1476A - K-divisible Sum

We are asked to construct an array of size $n$ containing positive integers such that the sum of all elements is divisible by $k$. Among all arrays that satisfy this condition, we need the one where the largest element is as small as possible.

codeforcescompetitive-programmingbinary-searchconstructive-algorithmsgreedymath
CF 1476C - Longest Simple Cycle

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingdpgraphsgreedy
CF 1476B - Inflation

We are given a sequence of monthly price increases for a single product. The first value represents the initial price, and each subsequent value is the nominal increase in that month.

codeforcescompetitive-programmingbinary-searchbrute-forcegreedymath
CF 1477D - Nezzar and Hidden Permutations

We are given an undirected graph on vertices 1..n. Every pair (l, r) chosen by Nanako becomes an edge of this graph. Nezzar must construct two permutations p and q of 1..n. For every edge (u, v), the differences p[u] - p[v] and q[u] - q[v] must have the same sign.

codeforcescompetitive-programmingconstructive-algorithmsdfs-and-similargraphs
CF 1477F - Nezzar and Chocolate Bars

Nezzar has a collection of chocolate bars with given lengths. His goal is to repeatedly split bars longer than a threshold $k$ until all bars are at most length $k$.

codeforcescompetitive-programmingcombinatoricsfftmathprobabilities
CF 1477E - Nezzar and Tournaments

We are given two teams of players, each with an integer potential. The first team has n players with potentials a1, a2, ..., an, and the second team has m players with potentials b1, b2, ..., bm.

codeforcescompetitive-programmingdata-structuresgreedy
CF 1477C - Nezzar and Nice Beatmap

We are given a set of $n$ distinct points on a 2D plane. Nezzar wants to reorder these points so that in the resulting sequence, every three consecutive points form an angle strictly less than 90 degrees at the middle point.

codeforcescompetitive-programmingconstructive-algorithmsgeometrygreedymathsortings
CF 1477B - Nezzar and Binary String

We start with a binary string that must eventually become another binary string after a sequence of operations. Each day, a fixed segment is inspected. If that segment contains both 0 and 1, the process immediately fails.

codeforcescompetitive-programmingdata-structuresgreedy
CF 1477A - Nezzar and Board

We are given a board with $n$ distinct integers, and we can repeatedly perform an operation that takes two numbers $x$ and $y$ from the board and writes down $2x - y$.

codeforcescompetitive-programmingconstructive-algorithmsmathnumber-theory
CF 1478C - Nezzar and Symmetric Array

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingimplementationmathsortings
CF 1478A - Nezzar and Colorful Balls

Nezzar has a sequence of balls, each labeled with a number from a non-decreasing array. He wants to color the balls using as few colors as possible with the rule that, if we isolate all balls of the same color, their numbers must strictly increase.

codeforcescompetitive-programmingbrute-forcegreedy
CF 1478B - Nezzar and Lucky Number

We are given a digit $d$ and a collection of queries. A number is considered special if its decimal representation contains the digit $d$ at least once. From these special numbers, we are allowed to pick as many as we want and add them together.

codeforcescompetitive-programmingbrute-forcedpgreedymath
CF 1479E - School Clubs

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingdpfftmathnumber-theoryprobabilities
CF 1479D - Odd Mineral Resource

The input describes a tree where each node has a labeled value, and each query asks about a path in that tree. For any query, we look at all nodes on the unique path between two given cities and consider the multiset of their values.

codeforcescompetitive-programmingbinary-searchbitmasksbrute-forcedata-structuresprobabilitiestrees
CF 1479C - Continuous City

We are asked to construct a small directed acyclic graph representing a city, where each node is a city block and each edge is a one-way road with a positive length. The key is to guarantee two properties simultaneously.

codeforcescompetitive-programmingbitmasksconstructive-algorithms
CF 1479B2 - Painting the Array II

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingconstructive-algorithmsdata-structuresdpgreedyimplementation
CF 1479A - Searching Local Minimum

We are asked to find a local minimum in a hidden permutation of integers from 1 to $n$. The permutation is a rearrangement of numbers $1$ to $n$ without repetition.

codeforcescompetitive-programmingbinary-searchinteractiveternary-search
CF 1479B1 - Painting the Array I

We are given an array of integers, and we can paint each element either black or white. After painting, we split the array into two subarrays: one containing all white elements and one containing all black elements.

codeforcescompetitive-programmingconstructive-algorithmsdata-structuresdpgreedyimplementation
CF 1480A - Yet Another String Game

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programminggamesgreedystrings
CF 1480B - The Great Hero

The problem presents a hero with fixed attack power and health facing a set of monsters, each with their own attack and health. Combat is turnless but simultaneous: when the hero attacks a monster, the monster also deals its attack damage back to the hero.

codeforcescompetitive-programminggreedyimplementationsortings
CF 1481F - AB Tree

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingdpgreedytrees
CF 1481E - Sorting Books

We have a row of books. Each book has a color. We may repeatedly choose any book and move it to the end of the row. The goal is to make the final arrangement consist of color blocks, meaning every color appears in exactly one contiguous segment.

codeforcescompetitive-programmingdata-structuresdpgreedy
CF 1481D - AB Graph

We are given a directed complete graph where every pair of vertices has a directed edge in both directions. Each directed edge is labeled with either a or b.

codeforcescompetitive-programmingbrute-forceconstructive-algorithmsgraphsgreedyimplementation
CF 1481B - New Colony

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingbrute-forcegreedyimplementation
CF 1481C - Fence Painting

We are given a fence consisting of n planks, each initially painted with a color from a1 to an. Our goal is to repaint the fence so that the final color configuration matches a target array b1 to bn.

codeforcescompetitive-programmingbrute-forceconstructive-algorithmsgreedy
CF 1481A - Space Navigation

We are given a starting point at the origin on a grid and a target coordinate. Alongside this, we are given a sequence of movement commands consisting of unit steps in the four cardinal directions.

codeforcescompetitive-programminggreedystrings
CF 1482H - Exam

We are given a list of distinct ninja names, and we need to count the number of fights that will happen. A fight occurs between two ninjas if one ninja's name is a substring of the other's, and there is no third ninja whose name is also a substring of the larger name and…

codeforcescompetitive-programmingdata-structuresstring-suffix-structurestrees
CF 1482G - Vabank

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingbinary-searchinteractive
CF 1482F - Useful Edges

We are given an undirected weighted graph with up to 600 vertices and up to about 180,000 edges, where each edge has a positive weight. Then we are given a list of queries, each consisting of a pair of vertices $u$ and $v$ and a number $l$.

codeforcescompetitive-programminggraphsshortest-paths
CF 1482C - Basic Diplomacy

We have m days. On each day, a specific set of friends is available, and we must choose exactly one available friend for that day. The assignment must satisfy a fairness condition. Let limit = ceil(m / 2). No friend may be chosen more than limit times across all days.

codeforcescompetitive-programmingbrute-forceconstructive-algorithmsgreedyimplementation
CF 1482E - Skyline Photo

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingdata-structuresdivide-and-conquerdp
CF 1482D - Playlist

We are asked to simulate a playlist with songs labeled by genres, where Arkady listens to songs in order, cycling back to the beginning when reaching the end.

codeforcescompetitive-programmingdata-structuresdsuimplementationshortest-paths
CF 1482B - Restore Modulo

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingimplementationmath
CF 1482A - Prison Break

We are given a prison represented as a rectangular grid of size a × b. Each cell is isolated by walls on all four sides except the perimeter, which leads to freedom.

codeforcescompetitive-programmingmath
CF 1485F - Copy or Prefix Sum

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingcombinatoricsdata-structuresdpsortings
CF 1485E - Move and Swap

We are given a rooted tree where every root-to-leaf path has the same length. Each non-root vertex has a value, while the root has no value attached. Two tokens start together at the root.

codeforcescompetitive-programmingdfs-and-similardpgreedytrees
CF 1485D - Multiples and Power Differences

We are given a two-dimensional grid of positive integers, where each cell contains a small number between 1 and 16.

codeforcescompetitive-programmingconstructive-algorithmsgraphsmathnumber-theory
CF 1485C - Floor and Mod

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingbinary-searchbrute-forcemathnumber-theory
CF 1485B - Replace and Keep Sorted

We are given a strictly increasing array a of length n with elements from 1 to k, and multiple queries asking about subarrays. For each query, defined by indices l and r, we need to count how many arrays b exist that are "k-similar" to the subarray a[l..r].

codeforcescompetitive-programmingdpimplementationmath
CF 1485A - Add and Divide

We are asked to reduce a positive integer a to zero using two operations: divide a by another positive integer b using integer division, or increment b by one. Each operation counts as one step, and the goal is to minimize the total number of steps.

codeforcescompetitive-programmingbrute-forcegreedymathnumber-theory
CF 1486F - Pairs of Paths

We are given a tree with n vertices, meaning a connected graph with n-1 edges and no cycles. Along with the tree, we are given m paths, each specified by its two endpoints u and v.

codeforcescompetitive-programmingcombinatoricsdata-structuresdfs-and-similardptrees
CF 1486E - Paired Payment

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingbinary-searchbrute-forceconstructive-algorithmsdpflowsgraphsshortest-paths
CF 1486D - Max Median

We are asked to find the largest possible median among all contiguous subarrays of a given array with length at least $k$.

codeforcescompetitive-programmingbinary-searchdata-structuresdp
CF 1486C2 - Guessing the Greatest (hard version)

We are given a hidden array of distinct values, and we can only interact with it through queries. Each query asks for a subsegment and returns the position of the second largest value inside that subsegment (but the index is reported in the original array).

codeforcescompetitive-programmingbinary-searchinteractive
CF 1486C1 - Guessing the Greatest (easy version)

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingbinary-searchinteractive
CF 1486A - Shifting Stacks

We are given a sequence of stacks, each with some number of blocks. The task is to decide if we can redistribute blocks, moving them only to the right, to make the stack heights strictly increasing.

codeforcescompetitive-programminggreedyimplementation
CF 1486B - Eastern Exhibition

We are given several independent test cases. In each test case there is a set of points on a 2D grid, representing houses.

codeforcescompetitive-programmingbinary-searchgeometryshortest-pathssortings
CF 1487G - String Counting

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingcombinatoricsdpfftmath
CF 1487C - Minimum Ties

We are asked to design the results of a round-robin football tournament so that every team ends up with the same number of points. There are $n$ teams, and each pair plays exactly once.

codeforcescompetitive-programmingbrute-forceconstructive-algorithmsdfs-and-similargraphsgreedyimplementationmath
CF 1487F - Ones

We are asked to build a number equal to a given large integer using only building blocks that are themselves made entirely of digit ‘1’. Each building block is an integer like 1, 11, 111, 1111 and so on, and we are allowed to add or subtract these blocks.

codeforcescompetitive-programmingdpgreedyshortest-paths
CF 1487E - Cheap Dinner

We have four layers of items. The first layer contains first courses, the second layer contains second courses, the third layer contains drinks, and the fourth layer contains desserts. Every item has a cost. Between every pair of adjacent layers, some combinations are forbidden.

codeforcescompetitive-programmingbrute-forcedata-structuresgraphsgreedyimplementationsortingstwo-pointers
CF 1487D - Pythagorean Triples

We are looking for integer triples $(a, b, c)$ such that $1 le a le b le c le n$. Two conditions must hold at the same time.

codeforcescompetitive-programmingbinary-searchbrute-forcemathnumber-theory
CF 1487B - Cat Cycle

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programmingmathnumber-theory
CF 1487A - Arena

We are given a collection of heroes, each with an initial strength or level. They fight pairwise, and whenever two heroes with different levels meet, the stronger one wins and grows stronger. If their levels are equal, the fight is a draw and nobody gains anything.

codeforcescompetitive-programmingimplementationsortings
CF 1488I - Demonic Invasion

The task describes a graph of islands connected by bidirectional bridges, where a disaster spreads outward from island 1 one layer per day.

codeforcescompetitive-programming*specialflows
CF 1488J - Flower Shop

We are managing a flower shop with n types of flowers, each with a fixed price. The shop starts empty, and a sequence of m operations is performed, either adding flowers to inventory, removing them, or asking for a count of distinct bouquets.

codeforcescompetitive-programming*specialdata-structuresfftmath
CF 1488H - Build From Suffixes

We are asked to construct strings of length $n$ using only the letters "a", "b", "c", and "d". For each position $i$ from $1$ to $n-1$, we are given a constraint $ai$.

codeforcescompetitive-programming*specialcombinatoricsdata-structures
CF 1488G - Painting Numbers

We are given a set of n distinct integers, each from 1 to n. The task is to assign each number a color, red or blue, such that exactly k numbers are red. The cost of a coloring is defined by counting all pairs (x, y) where x is blue, y is red, and y is divisible by x.

codeforcescompetitive-programming*specialdata-structuresgreedynumber-theory
CF 1488F - Dogecoin

Ann wants to maximize profit by mining and selling Dogecoin over a period of days. She earns exactly one coin per day she mines, and the price of a coin varies each day according to a given list.

codeforcescompetitive-programming*specialbinary-searchdata-structures
CF 1488E - Palindromic Doubles

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programming*specialdata-structuresdp
CF 1488D - Problemsolving Marathon

We are asked to construct a non-decreasing sequence of integers over a fixed number of days, where each day represents how many problems Polycarp solves.

codeforcescompetitive-programming*specialbinary-searchgreedy
CF 1488B - RBS Deletion

We are given a string of parentheses that is guaranteed to form a regular bracket sequence. Our goal is to repeatedly remove parts of the string according to two operation types until the string becomes empty.

codeforcescompetitive-programming*specialgreedy
CF 1488C - Two Policemen

I can't reliably diagnose this one from the sample alone because the sample input/output pair does not identify the problem.

codeforcescompetitive-programming*specialbinary-searchbrute-forcemath
CF 1488A - From Zero To Y

We start from zero and want to reach a target value using two kinds of increments. One increment is very small and uniform: we can always add 1 to the current value.

codeforcescompetitive-programming*specialmath