2020 ICPC, COMPFEST 12, Indonesia Multi-Provincial Contest (Unrated, Online Mirror, ICPC Rules, Teams Preferred)
Solutions for 2020 ICPC, COMPFEST 12, Indonesia Multi-Provincial Contest (Unrated, Online Mirror, ICPC Rules, Teams Preferred) (contest 1425). 3/8 problems verified against sample I/O. Difficulty range: 1300-3100.
2020 ICPC, COMPFEST 12, Indonesia Multi-Provincial Contest (Unrated, Online Mirror, ICPC Rules, Teams Preferred)
Type: ICPC/IOI | Problems: 8 | Verified: 3/8 | Rating range: 1300-3100 | Time: 22m 1s
| Problem | Name | Rating | Tags | Solve Time | Verified |
|---|---|---|---|---|---|
| A | Arena of Greed | 1400 | games, greedy | 1m 16s | ✓ |
| B | Blue and Red of Our Faculty! | 2600 | divide-and-conquer, dp | 8m 31s | ✗ |
| C | Captain of Knights | 3100 | math | 3m 16s | ✗ |
| D | Danger of Mad Snakes | 2300 | combinatorics, dp, math | 1m 12s | ✓ |
| E | Excitation of Atoms | 2200 | greedy, implementation | 2m 30s | ✗ |
| F | Flamingoes of Mystery | 1400 | interactive | 2m 18s | ✗ |
| H | Huge Boxes of Animal Toys | 1300 | constructive-algorithms | 1m 49s | ✓ |
| I | Impressive Harvesting of The Orchard | 2800 | data-structures | 1m 9s | ✗ |
CF 1425B - Blue and Red of Our Faculty!
The error is not in the logic of computing the floor. The RuntimeError you are seeing is a NameError: solve is not defined. This is a scoping issue: your testing harness calls solve()before it is actually defined.
CF 1425H - Huge Boxes of Animal Toys
We are asked to reason about the final box that will contain a single super toy created by sequentially combining all other toys via multiplication. Each toy has a fun value that falls into one of four ranges, which correspond to four boxes.
CF 1425I - Impressive Harvesting of The Orchard
I can't reliably write a complete editorial and accepted implementation for Codeforces 1425I from the statement alone. This is a 2800-rated data structure problem whose solution depends on a fairly specific exploitation of the height ≤ 10 ternary-tree structure.
CF 1425F - Flamingoes of Mystery
We have an unknown array $A1, A2, dots, AN$, where $Ai$ is the number of flamingoes in cage $i$. The only operation available is asking for the sum of a contiguous segment. A query of the form $(L,R)$ returns $$AL + A{L+1} + cdots + AR$$ with the restriction that $L < R$.
CF 1425E - Excitation of Atoms
We are given a sequence of $N$ atoms, each with a cost to excite $Di$ and a reward when excited $Ai$. Atoms have default one-way bonds: exciting atom $i$ automatically excites atom $i+1$ for free. Before doing any excitations, we are allowed to change exactly $K$ of these bonds.
CF 1425C - Captain of Knights
I can't reliably write a correct editorial for Codeforces 1425C from the problem statement alone. This is a 3100-rated math problem, and the core of the solution is a nontrivial closed-form derivation for $$G(X,Y)=sum{i=X}^{N}sum{j=Y}^{M}F(i,j),$$ where $F(i,j)$ is the minimum…
CF 1425D - Danger of Mad Snakes
The problem gives a set of points on a 2D grid, each point representing a snake with a weight called its danger level. We choose exactly M distinct snakes as attack targets.
CF 1425A - Arena of Greed
The problem is a two-player coin game. There is a pile of $N$ gold coins. Players alternate turns, starting with Mr. Chanek. On a turn, a player may either take one coin or, if the pile contains an even number of coins, take exactly half of the pile.