Codeforces Round 552 (Div. 3)

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
1154 Codeforces Round 552 (Div. 3) FINISHED False 7200 176397899 April 16, 2019, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 6348 ) E Two Teams PROGRAMMING data structures implementation sortings 1800

B'There are n students standing in a row. Two coaches are forming two teams -- the first coach chooses the first team and the second coach chooses the second team. The i -th student has integer programming skill a_i . All programming skills are distinct and between 1 and n , inclusive. Firstly, the first coach will choose the student with maximum programming skill among all students not taken into any team, and k closest students to the left of him and k closest students to the right of him (if there are less than k students to the left or to the right, all of them will be chosen). All students that are chosen leave the row and join the first team. Secondly, the second coach will make the same move (but all students chosen by him join the second team). Then again the first coach will make such move, and so on. This repeats until the row becomes empty (i. xe2 x80 x89e. the process ends when each student becomes to some team). Your problem is to determine which students will be taken into the first team and which students will be taken into the second team. The first line of the input contains two integers n and k ( 1 <= k <= n <= 2 cdot 10^5 ) -- the number of students and the value determining the range of chosen students during each move, respectively. The second line of the input contains n integers a_1, a_2, ... , a_n ( 1 <= a_i <= n ), where a_i is the programming skill of the i -th student. It is guaranteed that all programming skills are distinct. Print a string of n characters; i -th character should be 1 if i -th student joins the first team, or 2 otherwise. In the first example the first coach chooses the student on a position 3 , and the row becomes empty (all students join the first team). In the second example the first coach chooses the student on position 4 , and the row becomes [2, 1] (students with programming skills [3, '...

Tutorials

Codeforces Round #552 (Div. 3) Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
52955375 rom2718 E April 18, 2019, 1:33 p.m. OK Clang++17 Diagnostics TESTS 45 1512 27238400 1800
53375844 rr_ E April 26, 2019, 7:38 p.m. OK D TESTS 45 108 11571200 1800
53055029 PhuongPeu E April 20, 2019, 4:49 p.m. OK FPC TESTS 45 608 4096000 1800
57343311 sansen E July 19, 2019, 8:22 p.m. OK GNU C11 TESTS 45 31 3379200 1800
57343039 sansen E July 19, 2019, 8:09 p.m. OK GNU C11 TESTS 45 78 4198400 1800
53710163 rainboy E May 3, 2019, 3:11 p.m. OK GNU C11 TESTS 45 108 3379200 1800
53152936 WANDY666 E April 22, 2019, 3:59 p.m. OK GNU C11 TESTS 45 655 6656000 1800
53291214 gogogofuxk E April 25, 2019, 3:44 p.m. OK GNU C11 TESTS 45 702 9830400 1800
53183179 luogu_bot1 E April 23, 2019, 8:46 a.m. OK GNU C++11 TESTS 45 31 2457600 1800
54804229 Louhc E May 29, 2019, 1:17 p.m. OK GNU C++11 TESTS 45 31 4710400 1800
54804090 Louhc E May 29, 2019, 1:14 p.m. OK GNU C++11 TESTS 45 31 4710400 1800
54804247 Louhc E May 29, 2019, 1:18 p.m. OK GNU C++11 TESTS 45 31 4710400 1800
53183080 luogu_bot5 E April 23, 2019, 8:43 a.m. OK GNU C++11 TESTS 45 46 2457600 1800
63271099 Haworthia E Oct. 24, 2019, 4:10 a.m. OK GNU C++11 TESTS 45 46 3993600 1800
55489914 luogu_bot4 E June 12, 2019, 9:39 a.m. OK GNU C++11 TESTS 45 46 4403200 1800
53950597 luogu_bot1 E May 10, 2019, 9:19 a.m. OK GNU C++11 TESTS 45 46 4403200 1800
53042902 luogu_bot4 E April 20, 2019, 10:49 a.m. OK GNU C++11 TESTS 45 46 4608000 1800
55611064 ReaLNero1 E June 16, 2019, 5:45 a.m. OK GNU C++11 TESTS 45 46 4608000 1800
53734266 zstu_MingSD E May 4, 2019, 8:40 a.m. OK GNU C++14 TESTS 45 46 6656000 1800
53734162 zstu_MingSD E May 4, 2019, 8:37 a.m. OK GNU C++14 TESTS 45 46 6656000 1800
53027618 Lagrang3 E April 19, 2019, 8:16 p.m. OK GNU C++14 TESTS 45 77 3993600 1800
53283503 tuwuna E April 25, 2019, 12:58 p.m. OK GNU C++14 TESTS 45 77 4198400 1800
53029358 cometseeker1929 E April 19, 2019, 9:46 p.m. OK GNU C++14 TESTS 45 77 4198400 1800
53003684 tangbinjie E April 19, 2019, 8:29 a.m. OK GNU C++14 TESTS 45 77 4812800 1800
52923600 JoaquinManuel E April 17, 2019, 7:11 p.m. OK GNU C++14 TESTS 45 78 2457600 1800
53110090 gfonn E April 22, 2019, 1:14 a.m. OK GNU C++14 TESTS 45 78 2764800 1800
53013617 cheissmart E April 19, 2019, 1:11 p.m. OK GNU C++14 TESTS 45 78 3174400 1800
64087279 jack_guo E Nov. 2, 2019, 11:43 a.m. OK GNU C++14 TESTS 45 78 3174400 1800
53816767 interestingLSY E May 6, 2019, 11:01 a.m. OK GNU C++17 TESTS 45 46 5017600 1800
53850571 .tx E May 7, 2019, 1:15 p.m. OK GNU C++17 TESTS 45 46 8806400 1800
53158349 Amano_Sei E April 22, 2019, 4:23 p.m. OK GNU C++17 TESTS 45 62 3379200 1800
52939969 amatuer E April 18, 2019, 8:40 a.m. OK GNU C++17 TESTS 45 62 3481600 1800
53816790 HatsuneMikuo E May 6, 2019, 11:02 a.m. OK GNU C++17 TESTS 45 62 5017600 1800
52934431 FFFFFFFHHHHHHH E April 18, 2019, 5:27 a.m. OK GNU C++17 TESTS 45 77 3379200 1800
57624234 Biioy E July 24, 2019, 6:23 a.m. OK GNU C++17 TESTS 45 77 3993600 1800
52954650 danilserov E April 18, 2019, 1:17 p.m. OK GNU C++17 TESTS 45 77 6860800 1800
53733591 aDimitrov E May 4, 2019, 8:22 a.m. OK GNU C++17 TESTS 45 77 88473600 1800
53684282 oskarfiuk1 E May 2, 2019, 10:15 p.m. OK GNU C++17 TESTS 45 78 3174400 1800
63427123 120405217 E Oct. 26, 2019, 8:08 a.m. OK Go TESTS 45 218 4608000 1800
53168201 cs_office E April 22, 2019, 7:16 p.m. OK Go TESTS 45 842 14233600 1800
55328857 IBatJ E June 9, 2019, 9:44 a.m. OK Java 8 TESTS 45 139 0 1800
52956530 myacdream E April 18, 2019, 1:58 p.m. OK Java 8 TESTS 45 139 0 1800
55076279 IBatJ E June 4, 2019, 8:44 a.m. OK Java 8 TESTS 45 140 0 1800
53711859 Dukkha E May 3, 2019, 4:04 p.m. OK Java 8 TESTS 45 155 0 1800
56296726 JCKG E June 30, 2019, 6:26 a.m. OK Java 8 TESTS 45 170 2969600 1800
52958242 brainfxxk E April 18, 2019, 2:39 p.m. OK Java 8 TESTS 45 171 0 1800
53004190 vjudge1 E April 19, 2019, 8:44 a.m. OK Java 8 TESTS 45 187 0 1800
52933357 SpargelTarzan E April 18, 2019, 4:32 a.m. OK Java 8 TESTS 45 233 3072000 1800
56831563 Garett E July 11, 2019, 7:14 a.m. OK Java 8 TESTS 45 264 7680000 1800
52994625 programbhavan E April 19, 2019, 2:39 a.m. OK Java 8 TESTS 45 280 2969600 1800
53650718 heat_wave E May 2, 2019, 12:39 a.m. OK Kotlin TESTS 45 748 59392000 1800
57361326 thuutin E July 20, 2019, 7:49 a.m. OK Kotlin TESTS 45 920 41267200 1800
65238372 satyamcse E Nov. 17, 2019, 8:03 a.m. OK Kotlin TESTS 45 935 32051200 1800
65238579 satyamcse E Nov. 17, 2019, 8:07 a.m. OK Kotlin TESTS 45 951 32051200 1800
66206491 Spheniscine E Dec. 3, 2019, 3:28 a.m. OK Kotlin TESTS 45 1232 30412800 1800
52989265 Dimon2305 E April 18, 2019, 8:39 p.m. OK Mono C# TESTS 45 733 28569600 1800
53527770 ivanidze.kirov E April 29, 2019, 5:27 p.m. OK Mono C# TESTS 45 748 29388800 1800
53901269 vjudge2 E May 9, 2019, 10:19 a.m. OK MS C++ TESTS 45 77 3993600 1800
64518124 vjudge1 E Nov. 8, 2019, 11:27 a.m. OK MS C++ TESTS 45 77 4812800 1800
53194250 scorpiowf E April 23, 2019, 2:23 p.m. OK MS C++ TESTS 45 78 6041600 1800
53224044 vjudge2 E April 24, 2019, 1:25 p.m. OK MS C++ TESTS 45 93 3174400 1800
58518993 511019727 E Aug. 10, 2019, 2:55 a.m. OK MS C++ TESTS 45 93 3993600 1800
56738509 vjudge5 E July 9, 2019, 6:35 a.m. OK MS C++ TESTS 45 93 4812800 1800
56374486 vjudge3 E July 1, 2019, 5:53 a.m. OK MS C++ TESTS 45 93 4812800 1800
53705232 vjudge5 E May 3, 2019, 12:52 p.m. OK MS C++ TESTS 45 108 6553600 1800
63296120 vjudge1 E Oct. 24, 2019, 1:01 p.m. OK MS C++ TESTS 45 124 6041600 1800
56756923 vjudge2 E July 9, 2019, 2:17 p.m. OK MS C++ TESTS 45 140 3993600 1800
54494693 Kirja_ES E May 22, 2019, 5:09 p.m. OK MS C++ 2017 TESTS 45 93 8704000 1800
52931834 zcb E April 18, 2019, 3:04 a.m. OK MS C++ 2017 TESTS 45 109 3276800 1800
55109985 TOXait E June 5, 2019, 5:40 a.m. OK MS C++ 2017 TESTS 45 109 3993600 1800
53902965 shoulinniao E May 9, 2019, 11:19 a.m. OK MS C++ 2017 TESTS 45 109 3993600 1800
52931438 2462478392 E April 18, 2019, 2:38 a.m. OK MS C++ 2017 TESTS 45 124 4812800 1800
64565144 vjudge3 E Nov. 9, 2019, 7:27 a.m. OK MS C++ 2017 TESTS 45 171 3686400 1800
53606353 dewh E May 1, 2019, 10:35 a.m. OK MS C++ 2017 TESTS 45 202 7782400 1800
53214881 harm E April 24, 2019, 8:09 a.m. OK MS C++ 2017 TESTS 45 218 56934400 1800
53163330 CtrlAlt E April 22, 2019, 5:02 p.m. OK MS C++ 2017 TESTS 45 233 8908800 1800
52939425 MrLolthe1st E April 18, 2019, 8:24 a.m. OK MS C++ 2017 TESTS 45 280 3993600 1800
53674502 gatsko E May 2, 2019, 2:59 p.m. OK PyPy 2 TESTS 45 842 26828800 1800
53210289 radeye E April 24, 2019, 4:38 a.m. OK PyPy 3 TESTS 45 312 21811200 1800
55005169 bupt.wc E June 3, 2019, 7:07 a.m. OK PyPy 3 TESTS 45 436 45568000 1800
52990178 adshin21 E April 18, 2019, 9:21 p.m. OK PyPy 3 TESTS 45 592 21606400 1800
52944286 FadeoN E April 18, 2019, 10:50 a.m. OK PyPy 3 TESTS 45 702 27136000 1800
59503029 Novel E Aug. 26, 2019, 4:14 a.m. OK PyPy 3 TESTS 45 748 28774400 1800
53812768 xiaozhao E May 6, 2019, 8:08 a.m. OK PyPy 3 TESTS 45 748 36044800 1800
53667071 nexus.chebykin E May 2, 2019, 11:06 a.m. OK PyPy 3 TESTS 45 1684 30310400 1800
52924646 Mr.Inconsistent E April 17, 2019, 7:45 p.m. OK PyPy 3 TESTS 45 1809 55910400 1800
53272230 bupt.wc E April 25, 2019, 7:09 a.m. OK Python 3 TESTS 45 514 45260800 1800
53394839 ComradeMike E April 27, 2019, 8:40 a.m. OK Python 3 TESTS 45 529 27852800 1800
53537067 flandre2333 E April 30, 2019, 3:25 a.m. OK Python 3 TESTS 45 530 52019200 1800
53429322 vbshubham E April 27, 2019, 3:21 p.m. OK Python 3 TESTS 45 545 52019200 1800
53431117 sdhd E April 27, 2019, 4:21 p.m. OK Python 3 TESTS 45 561 21299200 1800
53164555 codershuvo E April 22, 2019, 5:27 p.m. OK Python 3 TESTS 45 576 40652800 1800
53200340 optimalnooo E April 23, 2019, 5:26 p.m. OK Python 3 TESTS 45 577 21299200 1800
52941899 echikawa E April 18, 2019, 9:40 a.m. OK Python 3 TESTS 45 748 30822400 1800
53927593 Lee0715 E May 9, 2019, 4:48 p.m. OK Python 3 TESTS 45 779 22528000 1800
53944796 Lee0715 E May 10, 2019, 5:57 a.m. OK Python 3 TESTS 45 795 21504000 1800
53459368 osa_k E April 28, 2019, 6:08 a.m. OK Rust TESTS 45 109 16384000 1800

remove filters

Back to search problems