Codeforces Global Round 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
1119 Codeforces Global Round 2 FINISHED False 7200 182975123 April 6, 2019, 11:35 a.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 11608 ) B Alyona and a Narrow Fridge PROGRAMMING binary search flows greedy sortings 1300

B'Alyona has recently bought a miniature fridge that can be represented as a matrix with h rows and 2 columns. Initially there is only one shelf at the bottom of the fridge, but Alyona can install arbitrary number of shelves inside the fridge between any two rows. A shelf is two cells wide, does not occupy any space but separates the inside of the fridge to the lower and upper part. Alyona has n bottles of milk that she wants to put in the fridge. The i -th bottle is a_i cells tall and 1 cell wide. She can put a bottle on some shelf if the corresponding space above the shelf is at least as tall as the bottle. She can not put a bottle on top of another bottle (if there is no shelf between them). Two bottles can not share a cell. Alyona is interested in the largest integer k such that she can put bottles 1 , 2 , ..., k in the fridge at the same time. Find this largest k . The first line contains two integers n and h ( 1 <= n <= 10^3 , 1 <= h <= 10^9 ) -- the number of bottles and the height of the fridge. The second line contains n integers a_1 , a_2 , ..., a_n ( 1 <= a_i <= h ) -- the heights of the bottles. Print the single integer k -- the maximum integer such that Alyona can put the bottles 1 , 2 , ..., k in the fridge at the same time. If Alyona can put all bottles in the fridge, print n . It is easy to see that Alyona can always put at least one bottle in the fridge. One of optimal locations in the first example is shown on the picture in the statement. One of optimal locations in the second example is shown on the picture below. One of optimal locations in the third example is shown on the picture below. '...

Tutorials

Codeforces Global Round 2 Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
69825880 vjudge4 B Jan. 30, 2020, 9:09 a.m. OK Clang++17 Diagnostics TESTS 33 62 8294400 1300
66527326 e.abbasniya B Dec. 9, 2019, 5:46 a.m. OK Clang++17 Diagnostics TESTS 33 233 307200 1300
52390814 hos.lyric B April 6, 2019, 11:52 a.m. OK D TESTS 33 31 4198400 1300
52388462 Gassa B April 6, 2019, 11:46 a.m. OK D TESTS 33 31 4198400 1300
52395259 ia7ck B April 6, 2019, 12:06 p.m. OK D TESTS 33 46 4198400 1300
52424880 Denor B April 6, 2019, 6:52 p.m. OK Delphi TESTS 33 31 0 1300
52419117 ruban B April 6, 2019, 4:22 p.m. OK Delphi TESTS 33 31 242892800 1300
52402901 d4rkn19ht B April 6, 2019, 12:42 p.m. OK FPC TESTS 33 30 307200 1300
52404219 dblark B April 6, 2019, 12:50 p.m. OK FPC TESTS 33 31 0 1300
52675205 dblark B April 13, 2019, 9:16 a.m. OK FPC TESTS 33 31 0 1300
52390431 Ngohavi B April 6, 2019, 11:51 a.m. OK FPC TESTS 33 31 102400 1300
52395798 AlifSaddid B April 6, 2019, 12:08 p.m. OK FPC TESTS 33 31 7987200 1300
52454688 Bear.-. B April 7, 2019, 11:14 a.m. OK FPC TESTS 33 46 307200 1300
52404470 Ahriman B April 6, 2019, 12:51 p.m. OK FPC TESTS 33 61 5120000 1300
52388989 sansen B April 6, 2019, 11:48 a.m. OK GNU C11 TESTS 33 31 0 1300
52422861 nipungoel11 B April 6, 2019, 5:54 p.m. OK GNU C11 TESTS 33 31 0 1300
52607257 paispls B April 11, 2019, 2:22 p.m. OK GNU C11 TESTS 33 31 0 1300
52715244 Raiden B April 13, 2019, 5:21 p.m. OK GNU C11 TESTS 33 31 0 1300
53085257 swaglorderu B April 21, 2019, 8:37 a.m. OK GNU C11 TESTS 33 31 0 1300
54736950 SKrPl B May 28, 2019, 5:34 a.m. OK GNU C11 TESTS 33 31 0 1300
52392321 zysbzddsj B April 6, 2019, 11:57 a.m. OK GNU C11 TESTS 33 31 0 1300
52677254 MYNAMEISSHARIFUL B April 13, 2019, 10:17 a.m. OK GNU C11 TESTS 33 31 16076800 1300
52408048 Nepumi B April 6, 2019, 1:12 p.m. OK GNU C11 TESTS 33 46 0 1300
52442529 akash19jain B April 7, 2019, 6:51 a.m. OK GNU C11 TESTS 33 46 0 1300
52391081 bupt_magicstar B April 6, 2019, 11:53 a.m. OK GNU C++11 TESTS 33 15 0 1300
52613374 SR421 B April 11, 2019, 5:05 p.m. OK GNU C++11 TESTS 33 30 0 1300
52676539 Andsc B April 13, 2019, 9:53 a.m. OK GNU C++11 TESTS 33 30 0 1300
52722677 ANZ1217 B April 13, 2019, 8:53 p.m. OK GNU C++11 TESTS 33 30 0 1300
53099226 Brodo0 B April 21, 2019, 3:22 p.m. OK GNU C++11 TESTS 33 30 0 1300
52605907 okoks9011 B April 11, 2019, 1:53 p.m. OK GNU C++11 TESTS 33 30 0 1300
54221639 FlappyFish B May 16, 2019, 3:44 a.m. OK GNU C++11 TESTS 33 30 0 1300
54472983 raj0510 B May 22, 2019, 6:42 a.m. OK GNU C++11 TESTS 33 30 0 1300
58500165 vjudge2 B Aug. 9, 2019, 1:55 p.m. OK GNU C++11 TESTS 33 30 0 1300
53817545 lighting_kissing B May 6, 2019, 11:28 a.m. OK GNU C++11 TESTS 33 30 0 1300
54440699 Lord_of_contests B May 21, 2019, 8:29 a.m. OK GNU C++14 TESTS 33 15 0 1300
68958088 chick_magnet B Jan. 16, 2020, 9:32 p.m. OK GNU C++14 TESTS 33 15 0 1300
66028295 vjudge1 B Nov. 30, 2019, 9:20 a.m. OK GNU C++14 TESTS 33 15 0 1300
63080387 vjudge1 B Oct. 21, 2019, 2:56 p.m. OK GNU C++14 TESTS 33 15 0 1300
57332647 who_knows B July 19, 2019, 2:48 p.m. OK GNU C++14 TESTS 33 15 0 1300
55282900 vjudge1 B June 8, 2019, 2:43 a.m. OK GNU C++14 TESTS 33 15 0 1300
55281838 vjudge1 B June 8, 2019, 1:50 a.m. OK GNU C++14 TESTS 33 15 0 1300
54913117 sharma34 B June 1, 2019, 12:15 p.m. OK GNU C++14 TESTS 33 15 0 1300
54653759 alpha_q2 B May 26, 2019, 7:04 a.m. OK GNU C++14 TESTS 33 15 0 1300
53111954 leomedeiros B April 22, 2019, 4:13 a.m. OK GNU C++14 TESTS 33 15 0 1300
54149162 IVIosab B May 14, 2019, 9:49 p.m. OK GNU C++17 TESTS 33 15 0 1300
53725099 oicoder_wqtwqtwqt B May 4, 2019, 3:35 a.m. OK GNU C++17 TESTS 33 15 0 1300
54871486 litelo674 B May 31, 2019, 9:29 a.m. OK GNU C++17 TESTS 33 15 0 1300
54883481 aryanv B May 31, 2019, 3:46 p.m. OK GNU C++17 TESTS 33 15 0 1300
55289326 1816020207 B June 8, 2019, 6:52 a.m. OK GNU C++17 TESTS 33 15 0 1300
57476181 alexOLO B July 21, 2019, 9:47 p.m. OK GNU C++17 TESTS 33 15 0 1300
58140590 hetp111 B Aug. 1, 2019, 5:57 p.m. OK GNU C++17 TESTS 33 15 0 1300
64878237 TianZuiXing B Nov. 14, 2019, 10:41 a.m. OK GNU C++17 TESTS 33 15 0 1300
65730726 killer_knight B Nov. 26, 2019, 4:53 a.m. OK GNU C++17 TESTS 33 15 0 1300
68945433 0-jij-0 B Jan. 16, 2020, 3:58 p.m. OK GNU C++17 TESTS 33 15 0 1300
52659021 suryanshv23 B April 12, 2019, 8:50 p.m. OK Go TESTS 33 77 0 1300
52398374 Dekedro B April 6, 2019, 12:19 p.m. OK Go TESTS 33 77 0 1300
52396515 avm B April 6, 2019, 12:11 p.m. OK Haskell TESTS 33 155 102400 1300
67268428 CodAR B Dec. 20, 2019, 7:08 a.m. OK Java 11 TESTS 33 202 0 1300
63879952 ijxjdjd B Oct. 30, 2019, 8:24 p.m. OK Java 8 TESTS 33 109 0 1300
64315641 ashcodish B Nov. 5, 2019, 2:02 p.m. OK Java 8 TESTS 33 109 0 1300
57302032 zekigurbuz TexanElite aswad2 B July 19, 2019, 12:49 a.m. OK Java 8 TESTS 33 109 0 1300
55834023 Dejokz B June 20, 2019, 2:29 p.m. OK Java 8 TESTS 33 109 0 1300
53276785 Musin B April 25, 2019, 9:53 a.m. OK Java 8 TESTS 33 109 0 1300
53103338 Keremet B April 21, 2019, 5:56 p.m. OK Java 8 TESTS 33 109 0 1300
52735168 happybelly B April 14, 2019, 6:11 a.m. OK Java 8 TESTS 33 109 0 1300
52682899 cribabby B April 13, 2019, 1:25 p.m. OK Java 8 TESTS 33 109 0 1300
52577290 Jetch B April 10, 2019, 5:02 p.m. OK Java 8 TESTS 33 109 0 1300
52509093 Akshita_Maheshwari B April 8, 2019, 8:45 p.m. OK Java 8 TESTS 33 109 0 1300
63959894 Spheniscine B Nov. 1, 2019, 4:33 a.m. OK Kotlin TESTS 33 140 921600 1300
63897412 Spheniscine B Oct. 31, 2019, 3:01 a.m. OK Kotlin TESTS 33 156 921600 1300
61871238 david_varela B Oct. 4, 2019, 6:16 p.m. OK Kotlin TESTS 33 170 1228800 1300
61871162 david_varela B Oct. 4, 2019, 6:15 p.m. OK Kotlin TESTS 33 171 1228800 1300
55157790 Mjgonzales B June 5, 2019, 3:52 p.m. OK Kotlin TESTS 33 171 1331200 1300
52393608 alexey.enkov B April 6, 2019, 12:01 p.m. OK Kotlin TESTS 33 186 1228800 1300
63770144 Spheniscine B Oct. 30, 2019, 7:41 a.m. OK Kotlin TESTS 33 202 921600 1300
52662413 yuizy B April 13, 2019, 1:19 a.m. OK Kotlin TESTS 33 218 614400 1300
52393577 Lishy2010 B April 6, 2019, 12:01 p.m. OK Kotlin TESTS 33 234 716800 1300
55188688 og.kostya B June 6, 2019, 5:19 a.m. OK Mono C# TESTS 33 62 0 1300
59264583 treasuryonly B Aug. 22, 2019, 10:05 a.m. OK Mono C# TESTS 33 62 102400 1300
52398656 IleksaNott B April 6, 2019, 12:20 p.m. OK Mono C# TESTS 33 62 102400 1300
52389792 eki B April 6, 2019, 11:50 a.m. OK Mono C# TESTS 33 77 102400 1300
52592586 Favarish B April 11, 2019, 6:48 a.m. OK Mono C# TESTS 33 77 102400 1300
52511493 dinarisio B April 8, 2019, 11:47 p.m. OK Mono C# TESTS 33 77 3686400 1300
52392186 riantkb B April 6, 2019, 11:56 a.m. OK Mono C# TESTS 33 77 3686400 1300
52390899 selpo B April 6, 2019, 11:53 a.m. OK Mono C# TESTS 33 77 3788800 1300
52399674 Rudolfking B April 6, 2019, 12:25 p.m. OK Mono C# TESTS 33 77 3891200 1300
52394762 claw88 B April 6, 2019, 12:04 p.m. OK Mono C# TESTS 33 77 3993600 1300
52668077 codeshaker B April 13, 2019, 5:57 a.m. OK MS C++ TESTS 33 15 0 1300
55093758 vjudge4 B June 4, 2019, 3:54 p.m. OK MS C++ TESTS 33 30 0 1300
56554101 vjudge3 B July 5, 2019, 11:31 a.m. OK MS C++ TESTS 33 30 0 1300
65613729 vjudge3 B Nov. 24, 2019, 1:49 a.m. OK MS C++ TESTS 33 31 0 1300
69816085 vjudge4 B Jan. 30, 2020, 6:12 a.m. OK MS C++ TESTS 33 31 0 1300
69822563 vjudge4 B Jan. 30, 2020, 8:18 a.m. OK MS C++ TESTS 33 31 0 1300
69824576 vjudge4 B Jan. 30, 2020, 8:50 a.m. OK MS C++ TESTS 33 31 0 1300
65296321 vjudge1 B Nov. 18, 2019, 11:39 a.m. OK MS C++ TESTS 33 31 0 1300
69815454 vjudge5 B Jan. 30, 2020, 6 a.m. OK MS C++ TESTS 33 31 0 1300
64879626 TianZuiXing B Nov. 14, 2019, 11:11 a.m. OK MS C++ TESTS 33 31 0 1300
52405128 Boryan07 B April 6, 2019, 12:55 p.m. OK MS C++ 2017 TESTS 33 30 0 1300
52488789 1816020205 B April 8, 2019, 10:40 a.m. OK MS C++ 2017 TESTS 33 30 0 1300
53802591 damaskenus B May 5, 2019, 8:05 p.m. OK MS C++ 2017 TESTS 33 31 0 1300
69821759 vjudge1 B Jan. 30, 2020, 8:05 a.m. OK MS C++ 2017 TESTS 33 31 0 1300
64879040 TianPingXing B Nov. 14, 2019, 10:58 a.m. OK MS C++ 2017 TESTS 33 31 0 1300
63408978 pmitkov B Oct. 25, 2019, 10:18 p.m. OK MS C++ 2017 TESTS 33 31 0 1300
56711619 omerb.zeybek B July 8, 2019, 12:56 p.m. OK MS C++ 2017 TESTS 33 31 0 1300
55967609 petko_mitkov B June 23, 2019, 1:01 p.m. OK MS C++ 2017 TESTS 33 31 0 1300
54896941 Lordxx B June 1, 2019, 3:35 a.m. OK MS C++ 2017 TESTS 33 31 0 1300
54896391 Lordxx B June 1, 2019, 3:08 a.m. OK MS C++ 2017 TESTS 33 31 0 1300
52444407 sash0 B April 7, 2019, 7:30 a.m. OK Ocaml TESTS 33 15 307200 1300
52393575 gmusya B April 6, 2019, 12:01 p.m. OK PascalABC.NET TESTS 33 389 7372800 1300
52430295 sas4eka B April 6, 2019, 10:06 p.m. OK Perl TESTS 33 61 0 1300
52430353 sas4eka B April 6, 2019, 10:10 p.m. OK Perl TESTS 33 108 204800 1300
52430406 sas4eka B April 6, 2019, 10:13 p.m. OK Perl TESTS 33 124 204800 1300
52430739 sas4eka B April 6, 2019, 10:34 p.m. OK Perl TESTS 33 124 307200 1300
52431399 sas4eka B April 6, 2019, 11:15 p.m. OK Perl TESTS 33 156 307200 1300
52431234 sas4eka B April 6, 2019, 11:04 p.m. OK Perl TESTS 33 171 307200 1300
52451350 sas4eka B April 7, 2019, 9:54 a.m. OK Perl TESTS 33 171 307200 1300
52431385 sas4eka B April 6, 2019, 11:15 p.m. OK Perl TESTS 33 171 307200 1300
52431020 sas4eka B April 6, 2019, 10:51 p.m. OK Perl TESTS 33 171 307200 1300
52431720 sas4eka B April 6, 2019, 11:32 p.m. OK Perl TESTS 33 187 307200 1300
56480009 mayakin B July 3, 2019, 3:34 p.m. OK PHP TESTS 33 108 0 1300
52423465 sy_chen B April 6, 2019, 6:12 p.m. OK PyPy 2 TESTS 33 124 102400 1300
52395579 allonsy_kim B April 6, 2019, 12:07 p.m. OK PyPy 2 TESTS 33 124 102400 1300
52392704 frederika B April 6, 2019, 11:58 a.m. OK PyPy 2 TESTS 33 124 204800 1300
52457084 Claustrophobic_Penguin B April 7, 2019, 12:10 p.m. OK PyPy 2 TESTS 33 124 307200 1300
52403819 deren B April 6, 2019, 12:47 p.m. OK PyPy 2 TESTS 33 124 307200 1300
52390091 c1729 B April 6, 2019, 11:51 a.m. OK PyPy 2 TESTS 33 139 0 1300
52388860 pajenegod B April 6, 2019, 11:48 a.m. OK PyPy 2 TESTS 33 140 102400 1300
52389454 kabeer27 B April 6, 2019, 11:49 a.m. OK PyPy 2 TESTS 33 155 716800 1300
52402854 codeseeker B April 6, 2019, 12:42 p.m. OK PyPy 2 TESTS 33 171 307200 1300
52478913 Zeround B April 8, 2019, 3:08 a.m. OK PyPy 2 TESTS 33 171 409600 1300
53024342 Bovniova B April 19, 2019, 6:10 p.m. OK PyPy 3 TESTS 33 124 102400 1300
52462175 nobe0716 B April 7, 2019, 1:54 p.m. OK PyPy 3 TESTS 33 124 102400 1300
52414992 H4Wk3ye B April 6, 2019, 2:58 p.m. OK PyPy 3 TESTS 33 124 102400 1300
52394745 H4Wk3ye B April 6, 2019, 12:04 p.m. OK PyPy 3 TESTS 33 139 102400 1300
53298012 Jarik B April 25, 2019, 6:33 p.m. OK PyPy 3 TESTS 33 140 102400 1300
52562961 jeqcho B April 10, 2019, 11:21 a.m. OK PyPy 3 TESTS 33 140 102400 1300
52490330 Leendertz B April 8, 2019, 11:21 a.m. OK PyPy 3 TESTS 33 140 102400 1300
52439978 alexwice B April 7, 2019, 6 a.m. OK PyPy 3 TESTS 33 140 102400 1300
52415038 lollihunter B April 6, 2019, 2:59 p.m. OK PyPy 3 TESTS 33 140 102400 1300
52396979 Kochan B April 6, 2019, 12:13 p.m. OK PyPy 3 TESTS 33 140 102400 1300
52478694 Uranux B April 8, 2019, 2:53 a.m. OK Python 2 TESTS 33 171 0 1300
52393263 Uranux B April 6, 2019, noon OK Python 2 TESTS 33 171 0 1300
62363582 muhitsarwar B Oct. 11, 2019, 1:12 p.m. OK Python 2 TESTS 33 186 0 1300
52398468 tangchuanxin B April 6, 2019, 12:19 p.m. OK Python 2 TESTS 33 187 102400 1300
52405126 nwi B April 6, 2019, 12:55 p.m. OK Python 2 TESTS 33 187 307200 1300
52415494 deecoder B April 6, 2019, 3:05 p.m. OK Python 2 TESTS 33 202 0 1300
55012448 kaif_7 B June 3, 2019, 10:45 a.m. OK Python 2 TESTS 33 233 204800 1300
52417731 Helli.code B April 6, 2019, 3:45 p.m. OK Python 2 TESTS 33 249 614400 1300
52650852 gatsko B April 12, 2019, 4:32 p.m. OK Python 2 TESTS 33 249 5324800 1300
52396024 slitvinov B April 6, 2019, 12:09 p.m. OK Python 2 TESTS 33 264 204800 1300
52425115 Forsten B April 6, 2019, 6:58 p.m. OK Python 3 TESTS 33 93 0 1300
59785343 vicwxz B Aug. 31, 2019, 5:21 a.m. OK Python 3 TESTS 33 109 307200 1300
55319910 Russell_Emerine B June 9, 2019, 3:25 a.m. OK Python 3 TESTS 33 109 307200 1300
54709622 Dmitry07 B May 27, 2019, 7:46 a.m. OK Python 3 TESTS 33 109 307200 1300
53000360 365050244 B April 19, 2019, 6:45 a.m. OK Python 3 TESTS 33 109 307200 1300
52923559 ComradeMike B April 17, 2019, 7:09 p.m. OK Python 3 TESTS 33 109 307200 1300
52582550 Black_Fregat B April 10, 2019, 8:11 p.m. OK Python 3 TESTS 33 109 307200 1300
52448588 nani_7 B April 7, 2019, 8:50 a.m. OK Python 3 TESTS 33 109 307200 1300
52429420 AverageName B April 6, 2019, 9:17 p.m. OK Python 3 TESTS 33 109 307200 1300
52400964 Lisanaaa B April 6, 2019, 12:32 p.m. OK Python 3 TESTS 33 109 307200 1300
52392920 koikotya B April 6, 2019, 11:58 a.m. OK Ruby TESTS 33 62 102400 1300
52395875 simanman B April 6, 2019, 12:08 p.m. OK Ruby TESTS 33 62 204800 1300
52399455 rinzu B April 6, 2019, 12:24 p.m. OK Ruby TESTS 33 109 0 1300
58398297 pikmike B Aug. 6, 2019, 4:33 p.m. OK Ruby TESTS 33 171 2560000 1300
60217037 Prof_BL B Sept. 7, 2019, 12:12 p.m. OK Ruby TESTS 33 171 3481600 1300
52424010 algmyr B April 6, 2019, 6:30 p.m. OK Ruby TESTS 33 202 3379200 1300
52601451 Dx18 B April 11, 2019, 12:05 p.m. OK Rust TESTS 33 31 0 1300
52394032 yakamoto B April 6, 2019, 12:02 p.m. OK Scala TESTS 33 436 0 1300

remove filters

Back to search problems