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 |
---|---|---|---|---|---|---|
1428 | Codeforces Raif Round 1 (Div. 1 + Div. 2) | FINISHED | False | 9000 | 134240063 | Oct. 17, 2020, 1:05 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 3756 ) | E | Carrots for Rabbits | PROGRAMMING | binary search data structures greedy math |
B'There are some rabbits in Singapore Zoo. To feed them, Zookeeper bought n carrots with lengths a_1, a_2, a_3, ldots, a_n . However, rabbits are very fertile and multiply very quickly. Zookeeper now has k rabbits and does not have enough carrots to feed all of them. To solve this problem, Zookeeper decided to cut the carrots into k pieces. For some reason, all resulting carrot lengths must be positive integers. Big carrots are very difficult for rabbits to handle and eat, so the time needed to eat a carrot of size x is x^2 . Help Zookeeper split his carrots while minimizing the sum of time taken for rabbits to eat the carrots. The first line contains two integers n and k (1 <= q n <= q k <= q 10^5) : the initial number of carrots and the number of rabbits. The next line contains n integers a_1, a_2, ldots, a_n (1 <= q a_i <= q 10^6) : lengths of carrots. It is guaranteed that the sum of a_i is at least k . Output one integer: the minimum sum of time taken for rabbits to eat carrots. For the first test, the optimal sizes of carrots are {1,1,1,2,2,2 } . The time taken is 1^2+1^2+1^2+2^2+2^2+2^2=15 For the second test, the optimal sizes of carrots are {4,5,5,5 } . The time taken is 4^2+5^2+5^2+5^2=91 . '... |
Codeforces Raif Round 1 Editorial |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
95832512 | Werner_Yin | E | Oct. 18, 2020, 12:31 a.m. | OK | GNU C++11 | TESTS | 24 | 31 | 3174400 | ||
95833366 | luogu_bot5 | E | Oct. 18, 2020, 1:16 a.m. | OK | GNU C++11 | TESTS | 24 | 31 | 3788800 | ||
95834635 | tianbu | E | Oct. 18, 2020, 2:06 a.m. | OK | GNU C++11 | TESTS | 24 | 31 | 3993600 | ||
95836628 | V--T_T--V | E | Oct. 18, 2020, 3:12 a.m. | OK | GNU C++11 | TESTS | 24 | 31 | 3993600 | ||
95802351 | hzk_cpp | E | Oct. 17, 2020, 3:20 p.m. | OK | GNU C++11 | TESTS | 23 | 31 | 4710400 | ||
95832327 | EmptySoulist | E | Oct. 18, 2020, 12:22 a.m. | OK | GNU C++11 | TESTS | 24 | 31 | 6348800 | ||
95833517 | luogu_bot5 | E | Oct. 18, 2020, 1:22 a.m. | OK | GNU C++11 | TESTS | 24 | 31 | 7680000 | ||
95833508 | I_LOVE_CWY | E | Oct. 18, 2020, 1:22 a.m. | OK | GNU C++11 | TESTS | 24 | 31 | 7680000 | ||
95805313 | onglu1 | E | Oct. 17, 2020, 3:29 p.m. | OK | GNU C++11 | TESTS | 23 | 31 | 7987200 | ||
95833180 | legend_life | E | Oct. 18, 2020, 1:08 a.m. | OK | GNU C++11 | TESTS | 24 | 31 | 7987200 | ||
95835464 | luciocf | E | Oct. 18, 2020, 2:35 a.m. | OK | GNU C++14 | TESTS | 24 | 31 | 3584000 | ||
95823035 | KhaledFarhat | E | Oct. 17, 2020, 7:20 p.m. | OK | GNU C++14 | TESTS | 24 | 46 | 3174400 | ||
95833470 | Hong_Shiba | E | Oct. 18, 2020, 1:20 a.m. | OK | GNU C++14 | TESTS | 24 | 46 | 3174400 | ||
95803445 | IgoRamli | E | Oct. 17, 2020, 3:24 p.m. | OK | GNU C++14 | TESTS | 23 | 46 | 3993600 | ||
95800956 | al3xstr33t | E | Oct. 17, 2020, 3:16 p.m. | OK | GNU C++14 | TESTS | 23 | 46 | 3993600 | ||
95838038 | work_hard. | E | Oct. 18, 2020, 3:52 a.m. | OK | GNU C++14 | TESTS | 24 | 46 | 4403200 | ||
95827756 | cryptomanic | E | Oct. 17, 2020, 9:06 p.m. | OK | GNU C++14 | TESTS | 24 | 46 | 4505600 | ||
95840012 | the_3rd_eye | E | Oct. 18, 2020, 4:47 a.m. | OK | GNU C++14 | TESTS | 24 | 46 | 4710400 | ||
95837117 | huynhsmd | E | Oct. 18, 2020, 3:26 a.m. | OK | GNU C++14 | TESTS | 24 | 46 | 4710400 | ||
95830476 | ayushgupta_ | E | Oct. 17, 2020, 10:46 p.m. | OK | GNU C++14 | TESTS | 24 | 46 | 4710400 | ||
95827291 | knightron00 | E | Oct. 17, 2020, 8:53 p.m. | OK | GNU C++17 | TESTS | 24 | 31 | 5529600 | ||
95840516 | unstoppable_N | E | Oct. 18, 2020, 4:59 a.m. | OK | GNU C++17 | TESTS | 24 | 46 | 2764800 | ||
95801900 | shurongwang | E | Oct. 17, 2020, 3:19 p.m. | OK | GNU C++17 | TESTS | 23 | 46 | 3174400 | ||
95831961 | tlnllkbp | E | Oct. 18, 2020, 12:02 a.m. | OK | GNU C++17 | TESTS | 24 | 46 | 3174400 | ||
95834621 | HChhokmah | E | Oct. 18, 2020, 2:06 a.m. | OK | GNU C++17 | TESTS | 24 | 46 | 3174400 | ||
95839716 | thantrongtri3 | E | Oct. 18, 2020, 4:40 a.m. | OK | GNU C++17 | TESTS | 24 | 46 | 3174400 | ||
95835248 | Jiburiru | E | Oct. 18, 2020, 2:26 a.m. | OK | GNU C++17 | TESTS | 24 | 46 | 3174400 | ||
95819182 | Altynai | E | Oct. 17, 2020, 6:15 p.m. | OK | GNU C++17 | TESTS | 24 | 46 | 3584000 | ||
95836689 | Harukaze_05 | E | Oct. 18, 2020, 3:14 a.m. | OK | GNU C++17 | TESTS | 24 | 46 | 3584000 | ||
95815087 | DanTheMan314 | E | Oct. 17, 2020, 5:14 p.m. | OK | GNU C++17 | TESTS | 24 | 46 | 3584000 | ||
95834989 | wistful23 | E | Oct. 18, 2020, 2:18 a.m. | OK | GNU C++17 (64) | TESTS | 24 | 31 | 4198400 | ||
95823526 | saketh | E | Oct. 17, 2020, 7:29 p.m. | OK | GNU C++17 (64) | TESTS | 24 | 31 | 4710400 | ||
95815342 | Eureka17 | E | Oct. 17, 2020, 5:18 p.m. | OK | GNU C++17 (64) | TESTS | 24 | 31 | 5017600 | ||
95834054 | wlzhouzhuan | E | Oct. 18, 2020, 1:45 a.m. | OK | GNU C++17 (64) | TESTS | 24 | 31 | 5017600 | ||
95814887 | Dormi | E | Oct. 17, 2020, 5:11 p.m. | OK | GNU C++17 (64) | TESTS | 24 | 31 | 5017600 | ||
95829100 | keepers | E | Oct. 17, 2020, 9:49 p.m. | OK | GNU C++17 (64) | TESTS | 24 | 31 | 5120000 | ||
95802307 | rappel | E | Oct. 17, 2020, 3:20 p.m. | OK | GNU C++17 (64) | TESTS | 23 | 31 | 5427200 | ||
95806425 | LiChenKoh | E | Oct. 17, 2020, 3:31 p.m. | OK | GNU C++17 (64) | TESTS | 23 | 31 | 5836800 | ||
95830289 | Svlad_Cjelli | E | Oct. 17, 2020, 10:37 p.m. | OK | GNU C++17 (64) | TESTS | 24 | 31 | 5836800 | ||
95802608 | tikul | E | Oct. 17, 2020, 3:21 p.m. | OK | GNU C++17 (64) | TESTS | 23 | 31 | 5836800 | ||
95826765 | chris_11 | E | Oct. 17, 2020, 8:40 p.m. | OK | Java 11 | TESTS | 24 | 202 | 8396800 | ||
95814192 | skittles1412 | E | Oct. 17, 2020, 5:02 p.m. | OK | Java 11 | TESTS | 24 | 218 | 0 | ||
95799052 | cirno3153 | E | Oct. 17, 2020, 3:10 p.m. | OK | Java 11 | TESTS | 23 | 233 | 0 | ||
95837151 | Agnimandur | E | Oct. 18, 2020, 3:27 a.m. | OK | Java 11 | TESTS | 24 | 264 | 1536000 | ||
95818950 | m.haghpanah | E | Oct. 17, 2020, 6:11 p.m. | OK | Java 11 | TESTS | 24 | 312 | 0 | ||
95806804 | dusty.and.rusty | E | Oct. 17, 2020, 3:32 p.m. | OK | Java 11 | TESTS | 23 | 358 | 3993600 | ||
95839908 | b0bl0blaw | E | Oct. 18, 2020, 4:44 a.m. | OK | Java 11 | TESTS | 24 | 373 | 0 | ||
95834883 | silver_sword | E | Oct. 18, 2020, 2:15 a.m. | OK | Java 11 | TESTS | 24 | 374 | 8806400 | ||
95811507 | awesomelemonade | E | Oct. 17, 2020, 4:32 p.m. | OK | Java 11 | TESTS | 24 | 389 | 0 | ||
95814464 | vaibhavpulastya | E | Oct. 17, 2020, 5:05 p.m. | OK | Java 11 | TESTS | 24 | 451 | 6246400 | ||
95828618 | fetetriste | E | Oct. 17, 2020, 9:33 p.m. | OK | Java 8 | TESTS | 24 | 140 | 0 | ||
95818798 | overACer | E | Oct. 17, 2020, 6:09 p.m. | OK | Java 8 | TESTS | 24 | 140 | 0 | ||
95830317 | derrick20 | E | Oct. 17, 2020, 10:38 p.m. | OK | Java 8 | TESTS | 24 | 171 | 0 | ||
95804703 | ijxjdjd | E | Oct. 17, 2020, 3:27 p.m. | OK | Java 8 | TESTS | 23 | 171 | 819200 | ||
95810673 | TheSawan | E | Oct. 17, 2020, 4:26 p.m. | OK | Java 8 | TESTS | 24 | 186 | 614400 | ||
95810963 | xwchen | E | Oct. 17, 2020, 4:28 p.m. | OK | Java 8 | TESTS | 24 | 218 | 8192000 | ||
95813589 | qlf9 | E | Oct. 17, 2020, 4:54 p.m. | OK | Java 8 | TESTS | 24 | 249 | 0 | ||
95831324 | hoffrj | E | Oct. 17, 2020, 11:25 p.m. | OK | Java 8 | TESTS | 24 | 280 | 3276800 | ||
95814540 | Jeg | E | Oct. 17, 2020, 5:06 p.m. | OK | Java 8 | TESTS | 24 | 295 | 0 | ||
95800713 | Slamur | E | Oct. 17, 2020, 3:16 p.m. | OK | Java 8 | TESTS | 23 | 311 | 0 | ||
95812396 | Tlatoani | E | Oct. 17, 2020, 4:40 p.m. | OK | Kotlin | TESTS | 24 | 233 | 204800 | ||
95811404 | koper | E | Oct. 17, 2020, 4:32 p.m. | OK | Kotlin | TESTS | 24 | 280 | 3993600 | ||
95818602 | areo | E | Oct. 17, 2020, 6:06 p.m. | OK | MS C++ 2017 | TESTS | 24 | 77 | 5120000 | ||
95822949 | P___ | E | Oct. 17, 2020, 7:19 p.m. | OK | MS C++ 2017 | TESTS | 24 | 78 | 4403200 | ||
95800360 | onp1978 | E | Oct. 17, 2020, 3:14 p.m. | OK | MS C++ 2017 | TESTS | 23 | 78 | 5427200 | ||
95811818 | baep_j | E | Oct. 17, 2020, 4:35 p.m. | OK | MS C++ 2017 | TESTS | 24 | 124 | 5222400 | ||
95843126 | fgwiebfaoish | E | Oct. 18, 2020, 5:51 a.m. | OK | .NET Core C# | TESTS | 24 | 124 | 13004800 | ||
95841317 | fgwiebfaoish | E | Oct. 18, 2020, 5:16 a.m. | OK | .NET Core C# | TESTS | 24 | 124 | 13107200 | ||
95828437 | R1val | E | Oct. 17, 2020, 9:27 p.m. | OK | .NET Core C# | TESTS | 24 | 155 | 14540800 | ||
95831956 | ngoc.ks | E | Oct. 18, 2020, 12:01 a.m. | OK | Node.js | TESTS | 24 | 327 | 28467200 | ||
95818942 | aberent | E | Oct. 17, 2020, 6:11 p.m. | OK | PyPy 3 | TESTS | 24 | 467 | 14438400 | ||
95810993 | kclee2172 | E | Oct. 17, 2020, 4:28 p.m. | OK | PyPy 3 | TESTS | 24 | 468 | 27340800 | ||
95835609 | m.ni | E | Oct. 18, 2020, 2:40 a.m. | OK | PyPy 3 | TESTS | 24 | 483 | 17408000 | ||
95814051 | marcus.test | E | Oct. 17, 2020, 5 p.m. | OK | PyPy 3 | TESTS | 24 | 592 | 15257600 | ||
95820829 | __eRRor__ | E | Oct. 17, 2020, 6:41 p.m. | OK | PyPy 3 | TESTS | 24 | 623 | 15667200 | ||
95825771 | nehan_der_thal | E | Oct. 17, 2020, 8:17 p.m. | OK | PyPy 3 | TESTS | 24 | 623 | 22630400 | ||
95812119 | tamato | E | Oct. 17, 2020, 4:38 p.m. | OK | PyPy 3 | TESTS | 24 | 655 | 15667200 | ||
95820384 | titia | E | Oct. 17, 2020, 6:34 p.m. | OK | PyPy 3 | TESTS | 24 | 670 | 13926400 | ||
95813152 | wolpiskerter | E | Oct. 17, 2020, 4:49 p.m. | OK | PyPy 3 | TESTS | 24 | 670 | 15667200 | ||
95815072 | Coki628 | E | Oct. 17, 2020, 5:14 p.m. | OK | PyPy 3 | TESTS | 24 | 701 | 13926400 | ||
95810685 | sh1194 | E | Oct. 17, 2020, 4:26 p.m. | OK | Python 3 | TESTS | 24 | 342 | 12288000 | ||
95825589 | prayashverma007 | E | Oct. 17, 2020, 8:13 p.m. | OK | Python 3 | TESTS | 24 | 343 | 9830400 | ||
95822703 | prayashverma007 | E | Oct. 17, 2020, 7:15 p.m. | OK | Python 3 | TESTS | 24 | 389 | 9728000 | ||
95830354 | Lotus007 | E | Oct. 17, 2020, 10:40 p.m. | OK | Python 3 | TESTS | 24 | 421 | 9625600 | ||
95834852 | Googler437 | E | Oct. 18, 2020, 2:14 a.m. | OK | Python 3 | TESTS | 24 | 421 | 9728000 | ||
95814415 | wolpiskerter | E | Oct. 17, 2020, 5:05 p.m. | OK | Python 3 | TESTS | 24 | 436 | 9216000 | ||
95821398 | cocopalm | E | Oct. 17, 2020, 6:50 p.m. | OK | Python 3 | TESTS | 24 | 467 | 11980800 | ||
95815101 | lowzhao | E | Oct. 17, 2020, 5:14 p.m. | OK | Python 3 | TESTS | 24 | 607 | 10649600 | ||
95803063 | ngtkana | E | Oct. 17, 2020, 3:23 p.m. | OK | Rust | TESTS | 23 | 109 | 6144000 |
Back to search problems