Anton Trygub Contest 1 (The 1st Universal Cup, Stage 4: Ukraine)
14 problems from Anton Trygub Contest 1 (The 1st Universal Cup, Stage 4: Ukraine) (contest 104197), difficulty -. 14/14 solutions verified against sample I/O.
Anton Trygub Contest 1 (The 1st Universal Cup, Stage 4: Ukraine)
Special | 14 problems | 14/14 verified | Difficulty - | 11m 35s
| # | Problem | Rating | Tags | Accepted | Time | ✓ |
|---|---|---|---|---|---|---|
| A | Adjacent Product Sum | 46s | ✓ | |||
| B | Binary Arrays and Sliding Sums | 46s | ✓ | |||
| C | Count Hamiltonian Cycles | 51s | ✓ | |||
| D | Distance Parities | 49s | ✓ | |||
| E | Excellent XOR Problem | 45s | ✓ | |||
| F | F*** 3-Colorable Graphs | 49s | ✓ | |||
| G | Graph Problem With Small $n$ | 53s | ✓ | |||
| H | Help Me to Get This Published | 50s | ✓ | |||
| I | Increasing Grid | 47s | ✓ | |||
| J | Jewel of Data Structure Problems | 53s | ✓ | |||
| K | King of Swapping | 54s | ✓ | |||
| L | Least Annoying Constructive Problem | 49s | ✓ | |||
| M | Most Annoying Constructive Problem | 50s | ✓ | |||
| N | No Zero-Sum Subsegment | 53s | ✓ |
CF 104197N - No Zero-Sum Subsegment
We are given a multiset of four types of moves that together describe a constrained walk on the integer line. Each type corresponds to a fixed step length and direction: some moves shift the position by 2 units to the left, some by 1 unit to the left, some by 1 unit to the…
CF 104197J - Jewel of Data Structure Problems
We are given a permutation of size $n$, and it is modified through a sequence of swaps. After each modification, we need to compute a value called the “beauty” of the current permutation.
CF 104197C - Count Hamiltonian Cycles
We are given a binary string of length 2n consisting of two types of vertices, W and B. We want to count Hamiltonian cycles over the 2n labeled vertices, but the cycle is constrained by a prefix-consistency condition: at every prefix i, the structure of how edges of the cycle…
CF 104197M - Most Annoying Constructive Problem
We are working with permutations of the numbers from 1 to n. Every contiguous segment of length at least two contributes a binary value: we classify each subarray as either “even” or “odd” based on a parity rule defined in the problem (which ultimately behaves like…
CF 104197K - King of Swapping
We are given a directed graph on $n$ vertices. Each vertex represents a position containing a number, and the graph encodes allowed moves of a distinguished element (the “king”) or, equivalently, allowed swaps between positions. A move is only possible along directed edges.
CF 104197L - Least Annoying Constructive Problem
We are given an odd number of vertices or an even number with a small adjustment, and we must explicitly construct a structured list of edges between labeled nodes.
CF 104197I - Increasing Grid
We are given an $n times m$ grid where some cells are already fixed to be either 0 or 1. Our task is to count how many full completions of the grid exist such that the final matrix is non-decreasing along both rows and columns, and all pre-filled constraints are satisfied.
CF 104197H - Help Me to Get This Published
We are working with a complete graph whose edges are colored, with the restriction that no triangle uses three distinct colors. This restriction is the classical Gallai property and it forces a strong hierarchical structure on how colors can appear across the graph.
CF 104197G - Graph Problem With Small $n$
We are given a graph with vertices numbered from 0 to n − 1, where n is small enough that we can consider subsets of vertices explicitly. The graph is undirected, and the core task revolves around reasoning about Hamiltonian paths that are constrained to subsets of vertices.
CF 104197F - F*** 3-Colorable Graphs
We are given a connected undirected graph. The vertices are already conceptually split into two groups by index, but that split is only used as a starting coloring trick: vertices in the first group can be colored differently from the second group so that the original graph is…
CF 104197D - Distance Parities
We are given a complete description of pairwise distances between nodes in a hypothetical graph, but only the parity of those distances matters.
CF 104197E - Excellent XOR Problem
We are given an array of integers, and the task is to decide whether it can be split into multiple contiguous parts under constraints defined by XOR values of these parts.
CF 104197A - Adjacent Product Sum
We are given a list of numbers and we want to place them around a circle. Once placed, every element contributes to the total score through the product with its two neighbors on the circle.
CF 104197B - Binary Arrays and Sliding Sums
We are working with binary arrays of length $n$, where each element is either 0 or 1. From any such array $a$, a derived array $b$ is defined through sliding sums over a fixed window size $k$.