Codeforces Round 571 (Div. 2)

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
1186 Codeforces Round 571 (Div. 2) FINISHED False 8100 170113199 June 28, 2019, 8:20 a.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 8962 ) D Vus the Cossack and Numbers PROGRAMMING constructive algorithms greedy math 1600

B'Vus the Cossack has n real numbers a_i . It is known that the sum of all numbers is equal to 0 . He wants to choose a sequence b the size of which is n such that the sum of all numbers is 0 and each b_i is either lfloor a_i rfloor or lceil a_i rceil . In other words, b_i equals a_i rounded up or down. It is not necessary to round to the nearest integer. For example, if a = [4.58413, 1.22491, -2.10517, -3.70387] , then b can be equal, for example, to [4, 2, -2, -4] . Note that if a_i is an integer, then there is no difference between lfloor a_i rfloor and lceil a_i rceil , b_i will always be equal to a_i . Help Vus the Cossack find such sequence! The first line contains one integer n ( 1 <= q n <= q 10^5 ) -- the number of numbers. Each of the next n lines contains one real number a_i ( |a_i| < 10^5 ). It is guaranteed that each a_i has exactly 5 digits after the decimal point. It is guaranteed that the sum of all the numbers is equal to 0 . In each of the next n lines, print one integer b_i . For each i , |a_i-b_i|<1 must be met. If there are multiple answers, print any. The first example is explained in the legend. In the second example, we can round the first and fifth numbers up, and the second and third numbers down. We can round the fourth number neither up, nor down. '...

Tutorials

E

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
56845588 med_amine D July 11, 2019, 1:29 p.m. OK Clang++17 Diagnostics TESTS 79 218 0 1600
57090435 Elwazer D July 15, 2019, 10:32 a.m. OK Clang++17 Diagnostics TESTS 79 561 2048000 1600
56222195 daut-dlang D June 28, 2019, 10:26 a.m. OK D TESTS 79 140 11878400 1600
56227599 LaSWeeG D June 28, 2019, 1:13 p.m. OK Delphi TESTS 79 186 1740800 1600
56280964 ruban D June 29, 2019, 4:46 p.m. OK Delphi TESTS 79 202 50483200 1600
66262783 Dbvivi D Dec. 4, 2019, 9:07 a.m. OK FPC TESTS 79 374 1638400 1600
56207727 TShT D June 28, 2019, 9:10 a.m. OK FPC TESTS 79 374 3584000 1600
56552331 bin9638 D July 5, 2019, 10:25 a.m. OK FPC TESTS 79 420 921600 1600
56215555 tiger0132 D June 28, 2019, 9:45 a.m. OK GNU C11 TESTS 79 124 921600 1600
56765237 TsReaper D July 9, 2019, 5:56 p.m. OK GNU C11 TESTS 79 389 1228800 1600
56276698 gargvibhor2012 D June 29, 2019, 2:37 p.m. OK GNU C11 TESTS 79 390 409600 1600
56532735 arko123 D July 4, 2019, 8:56 p.m. OK GNU C11 TESTS 79 390 1228800 1600
56382218 luciferkingofthehell D July 1, 2019, 8:56 a.m. OK GNU C11 TESTS 79 390 6041600 1600
56282079 md_mahbub D June 29, 2019, 5:24 p.m. OK GNU C11 TESTS 79 390 8396800 1600
56685095 You_Know_Who D July 7, 2019, 9:32 p.m. OK GNU C11 TESTS 79 405 0 1600
56684858 You_Know_Who D July 7, 2019, 9:17 p.m. OK GNU C11 TESTS 79 405 0 1600
61063301 nikhilreddy123 D Sept. 22, 2019, 10:10 a.m. OK GNU C11 TESTS 79 405 0 1600
66138477 Dream.to D Dec. 1, 2019, 1:19 p.m. OK GNU C11 TESTS 79 405 819200 1600
56847337 med_amine D July 11, 2019, 2:07 p.m. OK GNU C++11 TESTS 79 46 0 1600
56847229 med_amine D July 11, 2019, 2:05 p.m. OK GNU C++11 TESTS 79 46 0 1600
56848276 med_amine D July 11, 2019, 2:32 p.m. OK GNU C++11 TESTS 79 46 0 1600
56879284 med_amine D July 12, 2019, 9:38 a.m. OK GNU C++11 TESTS 79 46 0 1600
56257061 qq1010903229 D June 29, 2019, 6:33 a.m. OK GNU C++11 TESTS 79 46 614400 1600
56213873 searchstar D June 28, 2019, 9:37 a.m. OK GNU C++11 TESTS 79 46 716800 1600
56219306 G20202501 D June 28, 2019, 10:06 a.m. OK GNU C++11 TESTS 79 61 614400 1600
56216970 swust5120163956 D June 28, 2019, 9:51 a.m. OK GNU C++11 TESTS 79 61 1024000 1600
56206910 LKC314 D June 28, 2019, 9:06 a.m. OK GNU C++11 TESTS 79 61 1638400 1600
56277265 boomza654 D June 29, 2019, 2:54 p.m. OK GNU C++11 TESTS 79 62 819200 1600
56811154 CrazyMurky D July 10, 2019, 4:12 p.m. OK GNU C++14 TESTS 79 62 409600 1600
56492541 AMnu D July 3, 2019, 11:46 p.m. OK GNU C++14 TESTS 79 62 512000 1600
59519157 LucSac D Aug. 26, 2019, 11:14 a.m. OK GNU C++14 TESTS 79 62 512000 1600
57927912 krzysiek27 D July 29, 2019, 7:44 a.m. OK GNU C++14 TESTS 79 62 512000 1600
56227626 MikaPikazo D June 28, 2019, 1:14 p.m. OK GNU C++14 TESTS 79 62 512000 1600
56303711 ddolgu14 D June 30, 2019, 10:28 a.m. OK GNU C++14 TESTS 79 62 819200 1600
67211656 kawara_y D Dec. 19, 2019, 2:15 p.m. OK GNU C++14 TESTS 79 62 819200 1600
56251811 Black.n.White D June 29, 2019, 3:51 a.m. OK GNU C++14 TESTS 79 62 819200 1600
56254035 Aidos D June 29, 2019, 5:17 a.m. OK GNU C++14 TESTS 79 62 921600 1600
58153121 beginend D Aug. 2, 2019, 3:52 a.m. OK GNU C++14 TESTS 79 62 1228800 1600
57467533 lesskreker D July 21, 2019, 4:16 p.m. OK GNU C++17 TESTS 79 46 2048000 1600
56418892 YJHuang D July 2, 2019, 6:21 a.m. OK GNU C++17 TESTS 79 61 512000 1600
56554670 Helgui D July 5, 2019, 11:47 a.m. OK GNU C++17 TESTS 79 62 512000 1600
56210177 BdE D June 28, 2019, 9:21 a.m. OK GNU C++17 TESTS 79 62 819200 1600
56377752 dauzee D July 1, 2019, 7:14 a.m. OK GNU C++17 TESTS 79 62 819200 1600
56406259 gladkowskij D July 1, 2019, 7:34 p.m. OK GNU C++17 TESTS 79 62 819200 1600
56249449 ericxu0 D June 29, 2019, 1:30 a.m. OK GNU C++17 TESTS 79 62 921600 1600
56214624 Error_404 D June 28, 2019, 9:40 a.m. OK GNU C++17 TESTS 79 62 1536000 1600
66985881 mayank07 D Dec. 15, 2019, 6:05 p.m. OK GNU C++17 TESTS 79 62 1638400 1600
56210774 mango_lassi D June 28, 2019, 9:23 a.m. OK GNU C++17 TESTS 79 62 1638400 1600
57079795 efimmanevich D July 15, 2019, 6:50 a.m. OK Go TESTS 79 140 4505600 1600
63725168 prituladima D Oct. 29, 2019, 12:30 p.m. OK Java 11 TESTS 79 218 0 1600
68439560 mohamedyoussef D Jan. 9, 2020, 10:23 a.m. OK Java 11 TESTS 79 701 819200 1600
67945540 CodAR D Dec. 30, 2019, 5:03 a.m. OK Java 11 TESTS 79 701 819200 1600
68439490 mohamedyoussef D Jan. 9, 2020, 10:22 a.m. OK Java 11 TESTS 79 717 819200 1600
66187702 ILoveU3000 D Dec. 2, 2019, 3:11 p.m. OK Java 11 TESTS 79 997 0 1600
56259325 rahsutamrev D June 29, 2019, 7:26 a.m. OK Java 8 TESTS 79 140 0 1600
56269841 KharYusuf D June 29, 2019, 11:39 a.m. OK Java 8 TESTS 79 140 0 1600
60339761 xodiac D Sept. 10, 2019, 10:15 a.m. OK Java 8 TESTS 79 155 0 1600
56502991 atarw D July 4, 2019, 7:11 a.m. OK Java 8 TESTS 79 155 0 1600
56290066 heet_2201 D June 29, 2019, 11:30 p.m. OK Java 8 TESTS 79 155 0 1600
56276956 garg_vibhor D June 29, 2019, 2:44 p.m. OK Java 8 TESTS 79 155 0 1600
56265998 anuj560 D June 29, 2019, 9:54 a.m. OK Java 8 TESTS 79 155 0 1600
56263014 Anonymous9 D June 29, 2019, 8:49 a.m. OK Java 8 TESTS 79 155 0 1600
56259132 rahsutamrev D June 29, 2019, 7:21 a.m. OK Java 8 TESTS 79 155 0 1600
56254465 gaidash D June 29, 2019, 5:29 a.m. OK Java 8 TESTS 79 155 0 1600
56222342 orazbek D June 28, 2019, 10:27 a.m. OK JavaScript TESTS 79 109 15360000 1600
56211941 mongolrgata D June 28, 2019, 9:29 a.m. OK JavaScript TESTS 79 140 7577600 1600
56379093 kkyuggu D July 1, 2019, 7:43 a.m. OK Kotlin TESTS 79 171 0 1600
69505511 yakamoto D Jan. 25, 2020, 8:25 a.m. OK Kotlin TESTS 79 186 0 1600
56252279 Spheniscine D June 29, 2019, 4:14 a.m. OK Kotlin TESTS 79 312 307200 1600
56230485 sashamc D June 28, 2019, 2:06 p.m. OK Kotlin TESTS 79 358 1638400 1600
56252026 Spheniscine D June 29, 2019, 4:01 a.m. OK Kotlin TESTS 79 514 0 1600
56211891 mendel_vv D June 28, 2019, 9:29 a.m. OK Kotlin TESTS 79 936 0 1600
56230530 jonlik2 D June 28, 2019, 2:07 p.m. OK Kotlin TESTS 79 951 102400 1600
56216751 wbars D June 28, 2019, 9:50 a.m. OK Kotlin TESTS 79 998 512000 1600
56279408 -arg D June 29, 2019, 3:57 p.m. OK Kotlin TESTS 79 998 921600 1600
56229273 og.kostya D June 28, 2019, 1:42 p.m. OK Mono C# TESTS 79 78 3174400 1600
56208960 claw88 D June 28, 2019, 9:15 a.m. OK Mono C# TESTS 79 124 3993600 1600
56419034 treasuryonly D July 2, 2019, 6:25 a.m. OK Mono C# TESTS 79 124 7168000 1600
56301108 Giangvp D June 30, 2019, 8:56 a.m. OK Mono C# TESTS 79 717 3174400 1600
56208385 eki D June 28, 2019, 9:13 a.m. OK Mono C# TESTS 79 717 4710400 1600
56215423 Jarjar314 D June 28, 2019, 9:44 a.m. OK Mono C# TESTS 79 764 7168000 1600
56680924 NEvOl D July 7, 2019, 6:24 p.m. OK Mono C# TESTS 79 779 7065600 1600
56207942 lxhgww D June 28, 2019, 9:11 a.m. OK MS C++ TESTS 79 62 512000 1600
56210079 2017212212283 D June 28, 2019, 9:20 a.m. OK MS C++ TESTS 79 77 921600 1600
56293508 vjudge4 D June 30, 2019, 3:44 a.m. OK MS C++ TESTS 79 124 512000 1600
56214414 Hello_World3 D June 28, 2019, 9:39 a.m. OK MS C++ TESTS 79 139 819200 1600
59208890 vjudge2 D Aug. 21, 2019, 7:53 a.m. OK MS C++ TESTS 79 155 819200 1600
56276709 StarryNight D June 29, 2019, 2:37 p.m. OK MS C++ TESTS 79 155 819200 1600
57175351 vjudge1 D July 17, 2019, 5:18 a.m. OK MS C++ TESTS 79 155 1228800 1600
56297896 vjudge5 D June 30, 2019, 7:09 a.m. OK MS C++ TESTS 79 155 1228800 1600
56210398 Sorin1932 D June 28, 2019, 9:22 a.m. OK MS C++ TESTS 79 156 819200 1600
59209217 vjudge2 D Aug. 21, 2019, 7:58 a.m. OK MS C++ TESTS 79 156 1228800 1600
56364274 GorNix D June 30, 2019, 9:20 p.m. OK MS C++ 2017 TESTS 79 77 819200 1600
56670438 pmitkov D July 7, 2019, 12:53 p.m. OK MS C++ 2017 TESTS 79 93 819200 1600
61307812 vjudge2 D Sept. 26, 2019, 8:04 a.m. OK MS C++ 2017 TESTS 79 93 1228800 1600
56998266 Laaahu_ D July 14, 2019, 1:22 a.m. OK MS C++ 2017 TESTS 79 93 1638400 1600
56262576 xsc D June 29, 2019, 8:40 a.m. OK MS C++ 2017 TESTS 79 93 2048000 1600
56216382 youx D June 28, 2019, 9:48 a.m. OK MS C++ 2017 TESTS 79 93 2662400 1600
56290716 C20191522 D June 30, 2019, 12:26 a.m. OK MS C++ 2017 TESTS 79 108 1228800 1600
56220468 xietx D June 28, 2019, 10:13 a.m. OK MS C++ 2017 TESTS 79 109 512000 1600
56211637 j2v D June 28, 2019, 9:27 a.m. OK MS C++ 2017 TESTS 79 109 1228800 1600
56216386 GomBu D June 28, 2019, 9:48 a.m. OK MS C++ 2017 TESTS 79 109 1331200 1600
56237483 lostamok D June 28, 2019, 4:53 p.m. OK PHP TESTS 79 124 10547200 1600
58947048 mayakin D Aug. 17, 2019, 9:27 a.m. OK PHP TESTS 79 530 10035200 1600
56220913 raj1307 D June 28, 2019, 10:17 a.m. OK PyPy 2 TESTS 79 218 10854400 1600
56212690 Mukundan314 D June 28, 2019, 9:32 a.m. OK PyPy 2 TESTS 79 233 9318400 1600
56275213 snape_here D June 29, 2019, 1:54 p.m. OK PyPy 2 TESTS 79 233 10137600 1600
56236590 kabeer27 D June 28, 2019, 4:31 p.m. OK PyPy 2 TESTS 79 233 15462400 1600
56214481 yumtam D June 28, 2019, 9:40 a.m. OK PyPy 2 TESTS 79 249 10035200 1600
56210997 drd93 D June 28, 2019, 9:24 a.m. OK PyPy 2 TESTS 79 295 14950400 1600
56218688 minimalizam D June 28, 2019, 10:02 a.m. OK PyPy 2 TESTS 79 296 8089600 1600
56270544 snape_here D June 29, 2019, 11:55 a.m. OK PyPy 2 TESTS 79 296 9420800 1600
56220535 pa.n.ik D June 28, 2019, 10:14 a.m. OK PyPy 2 TESTS 79 452 12185600 1600
56217589 H4Wk3ye D June 28, 2019, 9:55 a.m. OK PyPy 3 TESTS 79 312 12595200 1600
57991792 Pokeylope D July 30, 2019, 1:31 p.m. OK PyPy 3 TESTS 79 374 14233600 1600
67969237 vyassamir D Dec. 30, 2019, 2:24 p.m. OK PyPy 3 TESTS 79 389 14336000 1600
56206191 titia D June 28, 2019, 9:03 a.m. OK PyPy 3 TESTS 79 390 9932800 1600
56236618 aberent D June 28, 2019, 4:31 p.m. OK PyPy 3 TESTS 79 405 20889600 1600
56236108 aberent D June 28, 2019, 4:19 p.m. OK PyPy 3 TESTS 79 420 22630400 1600
56219547 III_Wolverine_III D June 28, 2019, 10:07 a.m. OK PyPy 3 TESTS 79 436 10956800 1600
56214512 Paixao D June 28, 2019, 9:40 a.m. OK PyPy 3 TESTS 79 436 14643200 1600
57779108 StinsonOvO D July 26, 2019, 5:11 a.m. OK PyPy 3 TESTS 79 436 14848000 1600
56232563 vaibhavsarda D June 28, 2019, 2:49 p.m. OK PyPy 3 TESTS 79 436 18329600 1600
56237466 snape_here D June 28, 2019, 4:53 p.m. OK Python 2 TESTS 79 373 5427200 1600
56305719 TwentyFour D June 30, 2019, 11:41 a.m. OK Python 2 TESTS 79 389 1638400 1600
57796943 -Morass- D July 26, 2019, 11:47 a.m. OK Python 2 TESTS 79 405 4096000 1600
56209797 shubhankarsharma00 D June 28, 2019, 9:19 a.m. OK Python 2 TESTS 79 467 12083200 1600
56207890 psaini D June 28, 2019, 9:11 a.m. OK Python 2 TESTS 79 499 11059200 1600
56262118 bazzyadb D June 29, 2019, 8:29 a.m. OK Python 2 TESTS 79 810 12492800 1600
56218197 anshuman16423 D June 28, 2019, 9:59 a.m. OK Python 2 TESTS 79 841 2867200 1600
56214763 kaif_7 D June 28, 2019, 9:41 a.m. OK Python 2 TESTS 79 889 10649600 1600
56206304 tieros D June 28, 2019, 9:04 a.m. OK Python 3 TESTS 79 296 11571200 1600
63695276 QuantumKnight D Oct. 29, 2019, 5:09 a.m. OK Python 3 TESTS 79 389 5632000 1600
56207116 Sevlll D June 28, 2019, 9:07 a.m. OK Python 3 TESTS 79 405 8499200 1600
68842938 nealzane D Jan. 15, 2020, 6:27 a.m. OK Python 3 TESTS 79 405 10752000 1600
68706301 soodumb D Jan. 13, 2020, 11:25 a.m. OK Python 3 TESTS 79 452 5222400 1600
56232736 Vovkaez D June 28, 2019, 2:52 p.m. OK Python 3 TESTS 79 467 5427200 1600
56229972 maramsumanth D June 28, 2019, 1:55 p.m. OK Python 3 TESTS 79 467 11366400 1600
56230272 Mohamed_Ayman D June 28, 2019, 2:02 p.m. OK Python 3 TESTS 79 467 15667200 1600
56217445 junoflow D June 28, 2019, 9:54 a.m. OK Python 3 TESTS 79 483 5529600 1600
62963007 MinecraftFuns D Oct. 20, 2019, 2:25 a.m. OK Python 3 TESTS 79 483 6246400 1600
69282255 nikitaqqqq D Jan. 22, 2020, 6:31 a.m. OK Ruby TESTS 79 342 8908800 1600
57272443 corvvs_ D July 18, 2019, 9:24 a.m. OK Ruby TESTS 79 389 6144000 1600
56207234 koikotya D June 28, 2019, 9:08 a.m. OK Ruby TESTS 79 390 11878400 1600

remove filters

Back to search problems