| # | User | Rating |
|---|---|---|
| 1 | Benq | 3792 |
| 2 | VivaciousAubergine | 3647 |
| 3 | Kevin114514 | 3603 |
| 4 | jiangly | 3583 |
| 5 | strapple | 3515 |
| 6 | tourist | 3470 |
| 7 | dXqwq | 3436 |
| 8 | Radewoosh | 3415 |
| 9 | Otomachi_Una | 3413 |
| 10 | Um_nik | 3376 |
| # | User | Contrib. |
|---|---|---|
| 1 | Qingyu | 157 |
| 2 | adamant | 152 |
| 3 | Proof_by_QED | 146 |
| 3 | Um_nik | 146 |
| 5 | Dominater069 | 144 |
| 6 | errorgorn | 141 |
| 7 | cry | 139 |
| 8 | YuukiS | 135 |
| 9 | chromate00 | 134 |
| 9 | TheScrasse | 134 |
|
+5
The last part is a succession of max flow problems. And a linear seach is enough: you don't have to start from scratch every time, because adding edges to the graph doesn't affect the admissibility of the assignment. |
|
0
More precisely, there is exactly one cycle in every connected component (and it's length may be less than 3). |
|
+3
I think that the way you modelled the chemicals problem as a graph problem is useful. I suggest you to solve two special cases first:
And then you should be able to solve the original problem. |
|
+61
Suppose m is even. Let's call 'step' changing avery LR to UD and then every UD to LR, as done in matthew99's solution. We want to show that eventually all cells become L or R. A cell is 'stable' if it is L or R and it stays the same after performing an arbitrary number of steps. Suppose by contradiction there is a cell that never become stable, and consider the first one which has this property (it means that all the cells on the left and those placed in some preceding row eventually become stable. We can assume they are already stable, provided a sufficient number of steps has been performed). This cell must be U, and we can also determine the type of many other nearby cells, as shown: (asterisks denote stable cells, dots denote unknown cells). The same pattern must continue in diagonal until the border of the grid is reached. But this is impossible because there's no way to tile the cells above that diagonal using dominos (if you color them like a chessboard, the number of black cells and the number of white cells would be different). |
|
+4
Actually, most of the people who solved it used c++ |
|
+6
You can store many updates (say k updates) in one single node, and create its children only when you are attempting to insert the (k + 1)-th update. When querying, don't propagate the updates but consider all of them in O(k) time. |
|
+147
This is not a valid position, although only one connected component of size 18 needs to be tiled (X=6 on a 4x6 grid): |
|
0
During the contest I misread the limit for n (lenght of the string) in problem Div1-C, I thought it was n ≤ 10000. |
|
+1
Consider the devices starting from the top. Using a range tree you can calculate minimum in Do the same for the right side and the final answer will be of the form cL(i) + cR(i) - D[i] It works because (at least in the optimal set-up) the devices chosen for the left and right side are different, otherwise taking device i would be useless. |
|
+13
This was my key observation: it is sufficient that, if the ball appears in the leftmost and the rightmost column, it arrives in the same final column. |
|
+3
The link has been restored: today I've been able to download the test data. |
|
+1
Begin with the empty plane. |
|
0
I failed on the 4th problem just because I forgot to initialize my union-find disjoint set structure T_T |
|
0
For the last one: Order the points looking at the x-coordinate, and take the median point P. Then place a light at every point K such that y_K = y_P Work similarly on the left and on the right recursively... |
|
0
After the 0-command you should empty all the containers. |
|
+2
Without using trees: |
|
+10
He sent me the same message! Of course I ignored him... |
| Name |
|---|


