The 2018 ICPC Asia Qingdao Regional Programming Contest (The 1st Universal Cup, Stage 9: Qingdao)
13 problems from The 2018 ICPC Asia Qingdao Regional Programming Contest (The 1st Universal Cup, Stage 9: Qingdao) (contest 104270), difficulty -. 13/13 solutions verified against sample I/O.
The 2018 ICPC Asia Qingdao Regional Programming Contest (The 1st Universal Cup, Stage 9: Qingdao)
ICPC/IOI | 13 problems | 13/13 verified | Difficulty - | 12m 14s
| # | Problem | Rating | Tags | Accepted | Time | ✓ |
|---|---|---|---|---|---|---|
| A | Sequence and Sequence | 51s | ✓ | |||
| B | Kawa Exam | 1m 2s | ✓ | |||
| C | Flippy Sequence | 53s | ✓ | |||
| D | Magic Multiplication | 54s | ✓ | |||
| E | Plants vs. Zombies | 50s | ✓ | |||
| F | Tournament | 54s | ✓ | |||
| G | Repair the Artwork | 57s | ✓ | |||
| H | Mirror | 1m 7s | ✓ | |||
| I | Soldier Game | 48s | ✓ | |||
| J | Books | 1m 4s | ✓ | |||
| K | Airdrop | 53s | ✓ | |||
| L | Sub-cycle Graph | 1m 16s | ✓ | |||
| M | Function and Function | 45s | ✓ |
CF 104270L - Sub-cycle Graph
We are given a labeled undirected simple graph on $n$ vertices with exactly $m$ edges. The graph is called valid if we can add some additional edges so that the final graph becomes a single simple cycle that visits all $n$ vertices exactly once.
CF 104270M - Function and Function
We are given a number written in decimal form and a repeated transformation applied to it. The transformation is defined in two layers. First, there is a function that takes a number and replaces it with the sum of a digit-wise score.
CF 104270K - Airdrop
We are given a fixed target height $y0$ and a set of players, each starting at some integer grid point $(xi, yi)$. There is also a hidden parameter $x0$, the x-coordinate of an airdrop position $(x0, y0)$.
CF 104270J - Books
We are given a sequence of books, each with a fixed price, and a deterministic purchasing process that scans books from left to right. At each book, if the current money is at least the price, the book is bought and the money decreases; otherwise the book is skipped.
CF 104270I - Soldier Game
We are given an array of soldier powers arranged in a fixed order. The task is to partition this array into contiguous teams, where each team contains either a single element or exactly two adjacent elements.
CF 104270H - Mirror
We are given a start point and a target point in the plane. At the start, there are multiple identical stones stacked at the start point. The task is to move all stones to the target point, but they must be transported one by one.
CF 104270G - Repair the Artwork
We are given a line of $n$ cells, each cell being in one of three states. Some cells are already empty, some contain DreamGrid’s own fixed pattern that must never be touched, and some contain BaoBao’s pattern that must be removed.
CF 104270F - Tournament
We are asked to construct a multi-round tournament schedule among $n$ knights, where each round pairs up all knights into disjoint duels.
CF 104270D - Magic Multiplication
We are given the length of two unknown positive integers A and B, and a strange string C that is produced by multiplying them under a non-standard operation. The operation does not behave like normal multiplication.
CF 104270E - Plants vs. Zombies
We are given a line of plants indexed from 1 to n. Each plant i has a fixed position i and a growth rate a[i]. Initially every plant has zero defense value. A robot starts at position 0, which is the “house”.
CF 104270B - Kawa Exam
We are given an array of length $n$, where each position represents the correct answer to a multiple-choice question. Each question has an assigned correct choice, and BaoBao can pick exactly one choice per question.
CF 104270C - Flippy Sequence
We are given two binary strings of equal length. Think of them as two rows of switches, each position holding either 0 or 1. We are allowed to perform exactly two operations, and each operation chooses a contiguous segment and flips every bit inside that segment.
CF 104270A - Sequence and Sequence
We are given two tightly coupled sequences. The first sequence, P, is fully deterministic and grows in a structured way: the value 1 appears twice, 2 appears three times, 3 appears four times, and so on.