Codeforces Round 599 (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
1243 Codeforces Round 599 (Div. 2) FINISHED False 7200 158770499 Nov. 6, 2019, 3:05 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 15718 ) A Maximum Square PROGRAMMING implementation 800

B'Ujan decided to make a new wooden roof for the house. He has n rectangular planks numbered from 1 to n . The i -th plank has size a_i x 1 (that is, the width is 1 and the height is a_i ). Now, Ujan wants to make a square roof. He will first choose some of the planks and place them side by side in some order. Then he will glue together all of these planks by their vertical sides. Finally, he will cut out a square from the resulting shape in such a way that the sides of the square are horizontal and vertical. For example, if Ujan had planks with lengths 4 , 3 , 1 , 4 and 5 , he could choose planks with lengths 4 , 3 and 5 . Then he can cut out a 3 x 3 square, which is the maximum possible. Note that this is not the only way he can obtain a 3 x 3 square. What is the maximum side length of the square Ujan can get? The first line of input contains a single integer k ( 1 <= q k <= q 10 ), the number of test cases in the input. For each test case, the first line contains a single integer n ( 1 <= q n <= q 1 ,000 ), the number of planks Ujan has in store. The next line contains n integers a_1, ldots, a_n ( 1 <= q a_i <= q n ), the lengths of the planks. For each of the test cases, output a single integer, the maximum possible side length of the square. The first sample corresponds to the example in the statement. In the second sample, gluing all 4 planks will result in a 4 x 4 square. In the third sample, the maximum possible square is 1 x 1 and can be taken simply as any of the planks. '...

Tutorials

Codeforces Round #599 Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
69574802 vjudge4 A Jan. 26, 2020, 3:12 p.m. OK Clang++17 Diagnostics TESTS 17 46 3379200 800
67075602 Dariush_M A Dec. 17, 2019, 2:20 p.m. OK Clang++17 Diagnostics TESTS 17 77 0 800
64440667 atlantis9 A Nov. 7, 2019, 4:08 a.m. OK Clang++17 Diagnostics TESTS 17 78 0 800
64790589 vjudge5 A Nov. 13, 2019, 11:02 a.m. OK Clang++17 Diagnostics TESTS 17 108 0 800
64972050 FR4G-TP A Nov. 15, 2019, 4:31 a.m. OK Clang++17 Diagnostics TESTS 17 218 30720000 800
64727651 usentayev A Nov. 12, 2019, 7:06 a.m. OK FPC TESTS 17 30 0 800
64416929 duydec1 A Nov. 6, 2019, 5:01 p.m. OK FPC TESTS 17 31 0 800
69000528 vladislav_k A Jan. 17, 2020, 7:22 p.m. OK GNU C11 TESTS 17 15 0 800
64443392 Naveen_gupta A Nov. 7, 2019, 5:30 a.m. OK GNU C11 TESTS 17 30 0 800
66536816 acshai96 A Dec. 9, 2019, 9:56 a.m. OK GNU C11 TESTS 17 31 0 800
66573633 shubh101220001 A Dec. 10, 2019, 6:06 a.m. OK GNU C11 TESTS 17 31 0 800
66798066 Sujal123 A Dec. 13, 2019, 5:46 p.m. OK GNU C11 TESTS 17 31 0 800
67495358 akshatdalton A Dec. 23, 2019, 10:12 p.m. OK GNU C11 TESTS 17 31 0 800
68960663 Skolfide A Jan. 17, 2020, 12:24 a.m. OK GNU C11 TESTS 17 31 0 800
67672889 shadreza A Dec. 26, 2019, 9:52 p.m. OK GNU C11 TESTS 17 31 0 800
68216672 Nilachol A Jan. 5, 2020, 12:20 a.m. OK GNU C11 TESTS 17 31 0 800
68463450 khaledbougrine82 A Jan. 9, 2020, 7:06 p.m. OK GNU C11 TESTS 17 31 0 800
64477240 luojz A Nov. 7, 2019, 2:46 p.m. OK GNU C++11 TESTS 17 15 0 800
65161061 vjudge4 A Nov. 16, 2019, 11:23 a.m. OK GNU C++11 TESTS 17 15 0 800
64552313 YJSheep A Nov. 9, 2019, 12:45 a.m. OK GNU C++11 TESTS 17 15 0 800
65486147 wandisty A Nov. 21, 2019, 1:26 p.m. OK GNU C++11 TESTS 17 30 0 800
65756765 ChiNhan A Nov. 26, 2019, 2:16 p.m. OK GNU C++11 TESTS 17 30 0 800
66040067 priority A Nov. 30, 2019, 1:12 p.m. OK GNU C++11 TESTS 17 30 0 800
66207683 tran0826_1 A Dec. 3, 2019, 4:35 a.m. OK GNU C++11 TESTS 17 30 0 800
67764200 thebesttv A Dec. 28, 2019, 2:09 a.m. OK GNU C++11 TESTS 17 30 0 800
65259800 my_dream A Nov. 17, 2019, 2:39 p.m. OK GNU C++11 TESTS 17 30 0 800
65403984 worcher A Nov. 20, 2019, 1:39 a.m. OK GNU C++11 TESTS 17 30 0 800
69711268 namquan A Jan. 29, 2020, 7:08 a.m. OK GNU C++14 TESTS 17 15 0 800
69425330 biswajitghosh98 A Jan. 23, 2020, 3:37 p.m. OK GNU C++14 TESTS 17 15 0 800
69228800 GitanshSS A Jan. 21, 2020, 8:34 a.m. OK GNU C++14 TESTS 17 15 0 800
69424937 anshulgoel553 A Jan. 23, 2020, 3:30 p.m. OK GNU C++14 TESTS 17 15 0 800
69191020 vjudge1 A Jan. 20, 2020, 1:30 p.m. OK GNU C++14 TESTS 17 15 0 800
67664441 obaydullahmhs A Dec. 26, 2019, 5:13 p.m. OK GNU C++14 TESTS 17 15 0 800
67631792 prodipdatta7 A Dec. 26, 2019, 4:31 a.m. OK GNU C++14 TESTS 17 15 0 800
67058235 ashwin_rao A Dec. 17, 2019, 7:56 a.m. OK GNU C++14 TESTS 17 15 0 800
66659543 Oceil A Dec. 12, 2019, 3:21 a.m. OK GNU C++14 TESTS 17 15 0 800
66628786 kyrgyz.nomad A Dec. 11, 2019, 10:18 a.m. OK GNU C++14 TESTS 17 15 0 800
68220380 ZivFerdinand A Jan. 5, 2020, 4:14 a.m. OK GNU C++17 TESTS 17 15 0 800
69724307 tarek_3laa A Jan. 29, 2020, 11:45 a.m. OK GNU C++17 TESTS 17 15 0 800
68949913 rajprakrit A Jan. 16, 2020, 5:34 p.m. OK GNU C++17 TESTS 17 15 0 800
68690861 re_eVVorld A Jan. 13, 2020, 6:03 a.m. OK GNU C++17 TESTS 17 15 0 800
68485580 Anon_mouS A Jan. 10, 2020, 9:34 a.m. OK GNU C++17 TESTS 17 15 0 800
68201548 OrlandoIsay A Jan. 4, 2020, 4:05 p.m. OK GNU C++17 TESTS 17 15 0 800
68117987 FedShat A Jan. 3, 2020, 12:13 p.m. OK GNU C++17 TESTS 17 15 0 800
67875985 rama_pang A Dec. 29, 2019, 1:19 p.m. OK GNU C++17 TESTS 17 15 0 800
67853447 GUOshuai1017 A Dec. 29, 2019, 4:51 a.m. OK GNU C++17 TESTS 17 15 0 800
67437858 t1war1 A Dec. 22, 2019, 5:58 p.m. OK GNU C++17 TESTS 17 15 0 800
64681138 khochapak A Nov. 11, 2019, 10:03 a.m. OK Go TESTS 17 31 0 800
69007440 amarjeetanand A Jan. 18, 2020, 1:10 a.m. OK Go TESTS 17 46 0 800
64487188 sultan17 A Nov. 7, 2019, 6:15 p.m. OK Haskell TESTS 17 46 102400 800
64507263 sultan17 A Nov. 8, 2019, 7:24 a.m. OK Haskell TESTS 17 61 102400 800
65874568 XOR-star A Nov. 27, 2019, 4:35 p.m. OK Haskell TESTS 17 62 102400 800
65874395 XOR-star A Nov. 27, 2019, 4:33 p.m. OK Haskell TESTS 17 62 102400 800
64487793 sultan17 A Nov. 7, 2019, 6:31 p.m. OK Haskell TESTS 17 62 102400 800
67647843 cribabby A Dec. 26, 2019, 10:55 a.m. OK Java 11 TESTS 17 155 0 800
64490174 akina A Nov. 7, 2019, 7:34 p.m. OK Java 11 TESTS 17 156 0 800
65596187 pmurias A Nov. 23, 2019, 3:58 p.m. OK Java 11 TESTS 17 171 0 800
65508355 lpls1 A Nov. 22, 2019, 1:24 a.m. OK Java 11 TESTS 17 171 0 800
64561340 serafimkoo A Nov. 9, 2019, 6:09 a.m. OK Java 11 TESTS 17 171 0 800
67159784 kiberKotleta2009 A Dec. 18, 2019, 1:36 p.m. OK Java 11 TESTS 17 186 0 800
66368267 machhra A Dec. 5, 2019, 8:27 p.m. OK Java 11 TESTS 17 186 0 800
64643284 Vikital A Nov. 10, 2019, 1:59 p.m. OK Java 11 TESTS 17 186 0 800
65667531 findim A Nov. 24, 2019, 2:32 p.m. OK Java 11 TESTS 17 187 0 800
65225068 davisrollman A Nov. 17, 2019, 12:58 a.m. OK Java 11 TESTS 17 187 0 800
67391750 thisbeit A Dec. 21, 2019, 8:07 p.m. OK Java 8 TESTS 17 109 0 800
66620038 dyhu083 A Dec. 11, 2019, 6:33 a.m. OK Java 8 TESTS 17 109 0 800
66255313 Oopsimbad A Dec. 4, 2019, 5:33 a.m. OK Java 8 TESTS 17 109 0 800
65270990 RohanC A Nov. 17, 2019, 7:46 p.m. OK Java 8 TESTS 17 109 0 800
65160973 GreatWhite A Nov. 16, 2019, 11:21 a.m. OK Java 8 TESTS 17 109 0 800
64686889 aakashjaiswal A Nov. 11, 2019, noon OK Java 8 TESTS 17 109 0 800
64589058 vishal.a.burman23 A Nov. 9, 2019, 2:10 p.m. OK Java 8 TESTS 17 109 0 800
64572133 Witless_Deer A Nov. 9, 2019, 9:32 a.m. OK Java 8 TESTS 17 109 0 800
64528482 Avi_2506 A Nov. 8, 2019, 2:34 p.m. OK Java 8 TESTS 17 109 0 800
64468856 luchy0120 A Nov. 7, 2019, 12:30 p.m. OK Java 8 TESTS 17 109 0 800
64478358 walborn A Nov. 7, 2019, 3:06 p.m. OK JavaScript TESTS 17 46 3686400 800
68144954 I.A.K.O.V A Jan. 4, 2020, 3:33 a.m. OK Kotlin TESTS 17 124 0 800
65593917 derpderp A Nov. 23, 2019, 3:08 p.m. OK Kotlin TESTS 17 155 102400 800
64436883 Spheniscine A Nov. 7, 2019, 1:57 a.m. OK Kotlin TESTS 17 155 1024000 800
65582465 derpderp A Nov. 23, 2019, 11:25 a.m. OK Kotlin TESTS 17 156 102400 800
65580958 derpderp A Nov. 23, 2019, 11 a.m. OK Kotlin TESTS 17 170 204800 800
65592769 derpderp A Nov. 23, 2019, 2:44 p.m. OK Kotlin TESTS 17 171 102400 800
65587561 derpderp A Nov. 23, 2019, 12:59 p.m. OK Kotlin TESTS 17 171 102400 800
64504549 wcroughan A Nov. 8, 2019, 6:14 a.m. OK Kotlin TESTS 17 171 204800 800
64421023 Ahmadjon A Nov. 6, 2019, 5:52 p.m. OK Kotlin TESTS 17 171 204800 800
64652639 cripson1994 A Nov. 10, 2019, 5:55 p.m. OK Kotlin TESTS 17 171 1024000 800
64424640 TRR A Nov. 6, 2019, 6:47 p.m. OK Mono C# TESTS 17 46 716800 800
64751607 MrHalp A Nov. 12, 2019, 3:26 p.m. OK Mono C# TESTS 17 46 716800 800
65039497 hloya A Nov. 15, 2019, 12:55 p.m. OK Mono C# TESTS 17 46 716800 800
65712404 GusztavSzmolik A Nov. 25, 2019, 2:55 p.m. OK Mono C# TESTS 17 61 614400 800
64420965 Bdiebeake A Nov. 6, 2019, 5:51 p.m. OK Mono C# TESTS 17 62 614400 800
65030165 del7a A Nov. 15, 2019, 9:31 a.m. OK Mono C# TESTS 17 62 716800 800
64703617 hyzhangzhy A Nov. 11, 2019, 3:39 p.m. OK Mono C# TESTS 17 62 4403200 800
64590030 SpinDOS A Nov. 9, 2019, 2:28 p.m. OK Mono C# TESTS 17 62 4403200 800
65478450 ololonso A Nov. 21, 2019, 10:54 a.m. OK Mono C# TESTS 17 62 4403200 800
68317877 75number A Jan. 6, 2020, 1:51 p.m. OK Mono C# TESTS 17 62 4403200 800
65027725 vjudge1 A Nov. 15, 2019, 8:30 a.m. OK MS C++ TESTS 17 15 0 800
66453607 vjudge5 A Dec. 7, 2019, 12:22 p.m. OK MS C++ TESTS 17 30 0 800
66184304 vjudge2 A Dec. 2, 2019, 1:54 p.m. OK MS C++ TESTS 17 30 0 800
65161435 vjudge4 A Nov. 16, 2019, 11:32 a.m. OK MS C++ TESTS 17 30 0 800
64577109 962219923 A Nov. 9, 2019, 11:03 a.m. OK MS C++ TESTS 17 30 0 800
64684956 yanghuimin A Nov. 11, 2019, 11:26 a.m. OK MS C++ TESTS 17 30 204800 800
69246806 vjudge2 A Jan. 21, 2020, 1:09 p.m. OK MS C++ TESTS 17 31 0 800
69886049 vjudge3 A Jan. 31, 2020, 8:14 a.m. OK MS C++ TESTS 17 31 0 800
69286094 vjudge3 A Jan. 22, 2020, 8:14 a.m. OK MS C++ TESTS 17 31 0 800
69246853 vjudge3 A Jan. 21, 2020, 1:10 p.m. OK MS C++ TESTS 17 31 0 800
64434946 return-zan A Nov. 7, 2019, 12:34 a.m. OK MS C++ 2017 TESTS 17 30 0 800
65702945 cheng222 A Nov. 25, 2019, 11:31 a.m. OK MS C++ 2017 TESTS 17 31 0 800
69513303 baher_code_forces A Jan. 25, 2020, 11:11 a.m. OK MS C++ 2017 TESTS 17 31 0 800
68728208 Still_Theory A Jan. 13, 2020, 6:45 p.m. OK MS C++ 2017 TESTS 17 31 0 800
67341747 DM1 A Dec. 21, 2019, 11:33 a.m. OK MS C++ 2017 TESTS 17 31 0 800
66675999 vjudge4 A Dec. 12, 2019, 11:19 a.m. OK MS C++ 2017 TESTS 17 31 0 800
66452597 karinator A Dec. 7, 2019, 12:01 p.m. OK MS C++ 2017 TESTS 17 31 0 800
66397698 Tangerine A Dec. 6, 2019, 11:21 a.m. OK MS C++ 2017 TESTS 17 31 0 800
66397016 Tangerine A Dec. 6, 2019, 11:09 a.m. OK MS C++ 2017 TESTS 17 31 0 800
65942734 vjudge4 A Nov. 29, 2019, 7:07 a.m. OK MS C++ 2017 TESTS 17 31 0 800
65883863 fc-lib-xyz A Nov. 27, 2019, 8:41 p.m. OK Node.js TESTS 17 170 2252800 800
64407840 Jumabay A Nov. 6, 2019, 4:32 p.m. OK PascalABC.NET TESTS 17 327 204800 800
68158064 MaksimFedoseev A Jan. 4, 2020, 9:42 a.m. OK PascalABC.NET TESTS 17 358 307200 800
65730611 crismancilla36 A Nov. 26, 2019, 4:48 a.m. OK PascalABC.NET TESTS 17 374 204800 800
64429454 evgeny.poloznov A Nov. 6, 2019, 8:34 p.m. OK PHP TESTS 17 46 0 800
64467561 mayakin A Nov. 7, 2019, 12:09 p.m. OK PHP TESTS 17 46 0 800
64634868 Obada_Saleh A Nov. 10, 2019, 11:18 a.m. OK PHP TESTS 17 46 0 800
64452254 MAKARonin A Nov. 7, 2019, 7:31 a.m. OK PHP TESTS 17 61 409600 800
66187060 juned.ipe A Dec. 2, 2019, 2:55 p.m. OK PHP TESTS 17 842 409600 800
64416349 s_prateek11 A Nov. 6, 2019, 5 p.m. OK PyPy 2 TESTS 17 124 204800 800
64422939 electivire A Nov. 6, 2019, 6:17 p.m. OK PyPy 2 TESTS 17 140 921600 800
65535665 tayo_og A Nov. 22, 2019, 2:04 p.m. OK PyPy 2 TESTS 17 186 1228800 800
66773379 yumtam A Dec. 13, 2019, 8:56 a.m. OK PyPy 2 TESTS 17 202 1126400 800
64450547 Madhur1906 A Nov. 7, 2019, 6:55 a.m. OK PyPy 2 TESTS 17 218 204800 800
69885465 r_daniellivingston A Jan. 31, 2020, 8:02 a.m. OK PyPy 3 TESTS 17 140 1638400 800
68438207 akkisocc A Jan. 9, 2020, 9:51 a.m. OK PyPy 3 TESTS 17 140 1638400 800
64752538 bravech A Nov. 12, 2019, 3:45 p.m. OK PyPy 3 TESTS 17 140 1638400 800
64750659 MrsGoofy A Nov. 12, 2019, 3:06 p.m. OK PyPy 3 TESTS 17 140 1638400 800
64729665 udayps055 A Nov. 12, 2019, 7:54 a.m. OK PyPy 3 TESTS 17 140 1638400 800
64678193 spliey A Nov. 11, 2019, 8:55 a.m. OK PyPy 3 TESTS 17 140 1638400 800
64645826 _Temeraire A Nov. 10, 2019, 2:55 p.m. OK PyPy 3 TESTS 17 140 1638400 800
64641325 GlebNi A Nov. 10, 2019, 1:16 p.m. OK PyPy 3 TESTS 17 140 1638400 800
64572378 parthiv248 A Nov. 9, 2019, 9:37 a.m. OK PyPy 3 TESTS 17 140 1638400 800
64463703 pranaymalhan1 A Nov. 7, 2019, 11:10 a.m. OK PyPy 3 TESTS 17 140 1638400 800
69295584 bsr011 A Jan. 22, 2020, 12:05 p.m. OK Python 2 TESTS 17 186 102400 800
64512610 bertrandovide A Nov. 8, 2019, 9:23 a.m. OK Python 2 TESTS 17 186 102400 800
65590122 blueApple12 A Nov. 23, 2019, 1:50 p.m. OK Python 2 TESTS 17 187 102400 800
64661709 rdik A Nov. 10, 2019, 9:23 p.m. OK Python 2 TESTS 17 187 102400 800
64438850 aaa_bbb_ccc A Nov. 7, 2019, 3:03 a.m. OK Python 2 TESTS 17 187 102400 800
64423072 elistark A Nov. 6, 2019, 6:19 p.m. OK Python 2 TESTS 17 187 102400 800
65343066 khoatran_viet A Nov. 19, 2019, 11:39 a.m. OK Python 2 TESTS 17 202 102400 800
64427925 codelegend A Nov. 6, 2019, 7:55 p.m. OK Python 2 TESTS 17 202 102400 800
65535347 tayo_og A Nov. 22, 2019, 1:57 p.m. OK Python 2 TESTS 17 919 204800 800
67664589 cs1g A Dec. 26, 2019, 5:16 p.m. OK Python 3 TESTS 17 108 614400 800
64650125 CurtisBell A Nov. 10, 2019, 4:45 p.m. OK Python 3 TESTS 17 108 614400 800
65401441 vjudge2 A Nov. 19, 2019, 10:38 p.m. OK Python 3 TESTS 17 108 716800 800
64420083 aligh A Nov. 6, 2019, 5:45 p.m. OK Python 3 TESTS 17 108 819200 800
64426578 LintuStorm A Nov. 6, 2019, 7:24 p.m. OK Python 3 TESTS 17 108 921600 800
64771031 Ahmed_samir1312 A Nov. 12, 2019, 11:41 p.m. OK Python 3 TESTS 17 109 307200 800
64449171 doshisohesh A Nov. 7, 2019, 6:23 a.m. OK Python 3 TESTS 17 109 409600 800
68051257 mohi07 A Jan. 1, 2020, 6:58 p.m. OK Python 3 TESTS 17 109 512000 800
68022052 gautambp A Jan. 1, 2020, 12:42 a.m. OK Python 3 TESTS 17 109 512000 800
67989259 nealzane A Dec. 31, 2019, 2:56 a.m. OK Python 3 TESTS 17 109 512000 800
65937716 fshuto A Nov. 29, 2019, 3:40 a.m. OK Ruby TESTS 17 109 409600 800
64908278 httpsx A Nov. 15, 2019, 12:38 a.m. OK Ruby TESTS 17 732 9216000 800
66404143 manta1130 A Dec. 6, 2019, 1:11 p.m. OK Rust TESTS 17 31 204800 800
66221912 yuya178 A Dec. 3, 2019, 11:06 a.m. OK Rust TESTS 17 31 307200 800
64497530 AlexProk A Nov. 8, 2019, 1:22 a.m. OK Scala TESTS 17 436 0 800
64573451 hot.potato A Nov. 9, 2019, 10 a.m. OK Scala TESTS 17 467 0 800

remove filters

Back to search problems