| # | User | Rating |
|---|---|---|
| 1 | Benq | 3792 |
| 2 | VivaciousAubergine | 3647 |
| 3 | Kevin114514 | 3611 |
| 4 | jiangly | 3583 |
| 5 | strapple | 3515 |
| 6 | tourist | 3470 |
| 7 | Radewoosh | 3415 |
| 8 | Um_nik | 3376 |
| 9 | maroonrk | 3361 |
| 10 | XVIII | 3345 |
| # | User | Contrib. |
|---|---|---|
| 1 | Qingyu | 162 |
| 2 | adamant | 148 |
| 3 | Um_nik | 146 |
| 4 | Dominater069 | 143 |
| 5 | errorgorn | 141 |
| 6 | cry | 138 |
| 7 | Proof_by_QED | 136 |
| 8 | YuukiS | 135 |
| 9 | chromate00 | 134 |
| 10 | soullless | 133 |
|
+10
|
|
+5
The idea is interesting, but this is also incorrect: in the odd case, sticking to pairs may not be the best strategy of A: to mix pairs but exclude the worst one may yield smaller answer. Counterexample is this: Answer is 3, not 15. (A has 3 turns, and he excludes 50, 125, 140) |
|
+17
Were all the solutions of participants incorrect, too? |
|
0
What is wrong with while(hi-lo > 1e-9), exactly? I used long double there. |
|
0
Oh, thank you! But... What is going on?! You've changed only the sizes of arrays, but they were large enough in both submissions. |
|
0
Why is this 13576829 submission fails? I use 64-bit type here, so no overflow should occur. But is does... |
|
0
There is an another pair (2,2). We don't have a restriction l + s ≤ n |
|
+93
Problem H could be solved in O(1) without any binary search. Consider the case when a, b, c, d ≥ 0. Then define ![]() Take B as the above matrix. Then the answer in this case equals |x|. (But we strictly proved only that answer $\leq x$ ). If some of a, b, c, d are negative, this also holds, but better answer exist. We wanna get |a| + |b| + |c| + |d| in the denominator of x. One may note that if we have an even number of negative elements, it is possible to use the same B matrix, but reverse somewhere signs for x'es (and get ![]() Only essential case is if we have an odd number of negative elements in initial matrix. Then we have to subtract minimal element of (|a|, |b|, |c|, |d|) instead of adding, and answer equals ![]() However, I was unable to prove the minimality of x chosen this way during the contest (but solution got AC). Any ideas? |
| Name |
|---|


