Solutions are presented as using the least memory and the fastest execution time. It also takes the top 10 most recent solutions from each language. If you want to limit to a specific index, click the "Solved" button and go to that problem.
ContestId |
Name |
Phase |
Frozen |
Duration (Seconds) |
Relative Time |
Start Time |
|---|---|---|---|---|---|---|
| 2066 | Codeforces Round 1004 (Div. 1) | FINISHED | False | 7200 | 37121123 | Feb. 11, 2025, 2:35 p.m. |
Solved |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
|---|---|---|---|---|---|---|
| ( 420 ) | E | Tropical Season | PROGRAMMING | data structures greedy implementation |
You have (n) barrels of infinite capacity. The (i)-th barrel initially contains (a_i) kilograms of water. In this problem, we assume that all barrels weigh the same. You know that exactly one of the barrels has a small amount of tropical poison distributed on its surface, with a total weight of (0.179) kilograms. However, you do not know which barrel contains the poison. Your task is to identify this poisonous barrel. All the barrels are on scales. Unfortunately, the scales do not show the exact weight of each barrel. Instead, for each pair of barrels, they show the result of a comparison between the weights of those barrels. Thus, for any two barrels, you can determine whether their weights are equal, and if not, which barrel is heavier. The poison and water are included in the weight of the barrel. The scales are always turned on, and the information from them can be used an unlimited number of times. You also have the ability to pour water. You can pour water from any barrel into any other barrel in any amounts. However, to pour water, you must physically handle the barrel from which you are pouring, so if that happens to be the poisonous barrel, you will die. This outcome must be avoided. However, you can pour water into the poisonous barrel without touching it. In other words, you can choose the numbers (i, j, x) ((i \neq j, 1 \leq i, j \leq n, 0 < x \leq a_i), the barrel numbered (i) is not poisonous) and execute (a_i := a_i - x), (a_j := a_j + x). Where (x) is not necessarily an integer. Is it possible to guarantee the identification of which barrel contains the poison and remain alive using pouring and the information from the scales? You know that the poison is located on exactly one of the barrels. Additionally, we ask you to process (q) queries. In each query, either one of the existing barrels is removed, or an additional barrel with a certain amount of water is added. After each query, you need to an |
| 139415 |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
|---|---|---|---|---|---|---|---|---|---|---|---|
| 305735628 | -adhd- | E | Feb. 11, 2025, 10:07 p.m. | OK | C++17 (GCC 7-32) | TESTS | 102 | 562 | 52326400 | ||
| 305681002 | Um_nik | E | Feb. 11, 2025, 4:04 p.m. | OK | C++17 (GCC 7-32) | TESTS | 102 | 608 | 64000000 | ||
| 305694481 | Sai_t | E | Feb. 11, 2025, 4:29 p.m. | OK | C++17 (GCC 7-32) | TESTS | 102 | 1249 | 91443200 | ||
| 305706964 | alireza_kaviani | E | Feb. 11, 2025, 5:39 p.m. | OK | C++17 (GCC 7-32) | TESTS | 102 | 1671 | 206131200 | ||
| 305686363 | qwef_ | E | Feb. 11, 2025, 4:14 p.m. | OK | C++17 (GCC 7-32) | TESTS | 102 | 1687 | 192512000 | ||
| 305691669 | Little09 | E | Feb. 11, 2025, 4:24 p.m. | OK | C++17 (GCC 7-32) | TESTS | 102 | 2421 | 83148800 | ||
| 305699922 | tute7627 | E | Feb. 11, 2025, 4:34 p.m. | OK | C++20 (GCC 13-64) | TESTS | 102 | 359 | 42393600 | ||
| 305763095 | jerry3128 | E | Feb. 12, 2025, 5:59 a.m. | OK | C++20 (GCC 13-64) | TESTS | 102 | 577 | 27033600 | ||
| 305731104 | Mangooste | E | Feb. 11, 2025, 9:21 p.m. | OK | C++20 (GCC 13-64) | TESTS | 102 | 655 | 125337600 | ||
| 305680777 | dorijanlendvaj | E | Feb. 11, 2025, 4:04 p.m. | OK | C++20 (GCC 13-64) | TESTS | 102 | 671 | 46080000 | ||
| 305704059 | potato167 | E | Feb. 11, 2025, 5:25 p.m. | OK | C++20 (GCC 13-64) | TESTS | 102 | 764 | 123289600 | ||
| 305739762 | cxm1024 | E | Feb. 11, 2025, 11:50 p.m. | OK | C++20 (GCC 13-64) | TESTS | 102 | 827 | 137932800 | ||
| 305732202 | Nutella3001 | E | Feb. 11, 2025, 9:40 p.m. | OK | C++20 (GCC 13-64) | TESTS | 102 | 921 | 230400000 | ||
| 305695872 | umbrella-leaf | E | Feb. 11, 2025, 4:29 p.m. | OK | C++20 (GCC 13-64) | TESTS | 102 | 936 | 45056000 | ||
| 305706317 | powdersnow | E | Feb. 11, 2025, 5:35 p.m. | OK | C++20 (GCC 13-64) | TESTS | 102 | 984 | 37580800 | ||
| 305742003 | AzZr_KZ | E | Feb. 12, 2025, 12:46 a.m. | OK | C++20 (GCC 13-64) | TESTS | 102 | 1078 | 117248000 | ||
| 305692647 | maroonrk | E | Feb. 11, 2025, 4:26 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 102 | 296 | 43622400 | ||
| 305741642 | NetSpeed1 | E | Feb. 12, 2025, 12:37 a.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 102 | 624 | 228556800 | ||
| 305731965 | Mangooste | E | Feb. 11, 2025, 9:36 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 102 | 671 | 125440000 | ||
| 305708084 | irkstepanov | E | Feb. 11, 2025, 5:44 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 102 | 812 | 92672000 | ||
| 305696381 | squareOf105 | E | Feb. 11, 2025, 4:30 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 102 | 1093 | 25702400 | ||
| 305693640 | strapple | E | Feb. 11, 2025, 4:27 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 102 | 1155 | 134144000 | ||
| 305675358 | ksun48 | E | Feb. 11, 2025, 3:54 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 102 | 1249 | 61440000 | ||
| 305761136 | Augenstern | E | Feb. 12, 2025, 5:37 a.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 102 | 1359 | 240537600 | ||
| 305671371 | Kevin114514 | E | Feb. 11, 2025, 3:47 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 102 | 1375 | 396185600 | ||
| 305686452 | jiangly | E | Feb. 11, 2025, 4:14 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 102 | 1405 | 37478400 | ||
| 305718987 | rainboy | E | Feb. 11, 2025, 7:01 p.m. | OK | GNU C11 | TESTS | 102 | 1233 | 27750400 | ||
| 305716233 | Egor | E | Feb. 11, 2025, 6:38 p.m. | OK | Rust 2021 | TESTS | 102 | 1999 | 88064000 |
Back to search problems