Codeforces Round 703 (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
1486 Codeforces Round 703 (Div. 2) FINISHED False 8100 123521063 Feb. 18, 2021, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 7634 ) D Max Median PROGRAMMING binary search data structures dp two pointers

B'You are a given an array a of length n . Find a subarray a[l..r] with length at least k with the largest median. A median in an array of length n is an element which occupies position number lfloor frac{n + 1}{2} rfloor after we sort the elements in non-decreasing order. For example: median([1, 2, 3, 4]) = 2 , median([3, 2, 1]) = 2 , median([2, 1, 2, 1]) = 1 . Subarray a[l..r] is a contiguous part of the array a , i. e. the array a_l,a_{l+1}, ldots,a_r for some 1 <= q l <= q r <= q n , its length is r - l + 1 . The first line contains two integers n and k ( 1 <= q k <= q n <= q 2 cdot 10^5 ). The second line contains n integers a_1, a_2, ldots, a_n ( 1 <= q a_i <= q n ). Output one integer m -- the maximum median you can get. In the first example all the possible subarrays are [1..3] , [1..4] , [1..5] , [2..4] , [2..5] and [3..5] and the median for all of them is 2 , so the maximum possible median is 2 too. In the second example median([3..4]) = 3 . '...

Tutorials

Codeforces Round #703 (Div. 2) Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
107895055 wwlw D Feb. 19, 2021, 2:03 a.m. OK GNU C++11 TESTS 40 31 1433600
107898872 NamelessOIer D Feb. 19, 2021, 3:25 a.m. OK GNU C++11 TESTS 40 31 1638400
107896311 xfzlq D Feb. 19, 2021, 2:34 a.m. OK GNU C++11 TESTS 40 31 1638400
107895506 5ab D Feb. 19, 2021, 2:14 a.m. OK GNU C++11 TESTS 40 31 2252800
107900776 333lfy D Feb. 19, 2021, 3:57 a.m. OK GNU C++11 TESTS 40 46 1638400
107894759 fanfansann D Feb. 19, 2021, 1:55 a.m. OK GNU C++11 TESTS 40 46 1638400
107894331 onglu1 D Feb. 19, 2021, 1:44 a.m. OK GNU C++11 TESTS 40 46 1638400
107869821 Fairicle D Feb. 18, 2021, 5:43 p.m. OK GNU C++11 TESTS 39 46 1638400
107904815 chenchichi222 D Feb. 19, 2021, 4:57 a.m. OK GNU C++11 TESTS 40 46 2457600
107891488 Wall_breaker D Feb. 18, 2021, 11:57 p.m. OK GNU C++11 TESTS 40 46 2457600
107897855 _JJ D Feb. 19, 2021, 3:07 a.m. OK GNU C++14 TESTS 40 62 1638400
107898912 201901060324 D Feb. 19, 2021, 3:26 a.m. OK GNU C++14 TESTS 40 77 1638400
107873245 guestIT D Feb. 18, 2021, 6:03 p.m. OK GNU C++14 TESTS 39 77 1638400
107871386 mg_123 D Feb. 18, 2021, 5:50 p.m. OK GNU C++14 TESTS 39 77 1638400
107902428 zhangxiao D Feb. 19, 2021, 4:25 a.m. OK GNU C++14 TESTS 40 77 2457600
107910108 RaunakJain D Feb. 19, 2021, 6:01 a.m. OK GNU C++14 TESTS 40 77 3174400
107886528 Matei D Feb. 18, 2021, 9:06 p.m. OK GNU C++14 TESTS 40 77 3174400
107893077 ShubhamAvasthi D Feb. 19, 2021, 1:05 a.m. OK GNU C++14 TESTS 40 78 819200
107909332 ishan008 D Feb. 19, 2021, 5:52 a.m. OK GNU C++14 TESTS 40 78 1638400
107905579 bansalkanha68 D Feb. 19, 2021, 5:07 a.m. OK GNU C++14 TESTS 40 78 1638400
107880126 kakarot__ D Feb. 18, 2021, 7:14 p.m. OK GNU C++17 TESTS 39 62 1536000
107909920 Phantom_Killer D Feb. 19, 2021, 5:59 a.m. OK GNU C++17 TESTS 40 77 1638400
107903254 Xuu D Feb. 19, 2021, 4:36 a.m. OK GNU C++17 TESTS 40 77 1638400
107902819 WarYan D Feb. 19, 2021, 4:30 a.m. OK GNU C++17 TESTS 40 77 1638400
107902498 huangzhen D Feb. 19, 2021, 4:26 a.m. OK GNU C++17 TESTS 40 77 1638400
107901689 forceac D Feb. 19, 2021, 4:14 a.m. OK GNU C++17 TESTS 40 77 1638400
107897942 danielcm586 D Feb. 19, 2021, 3:08 a.m. OK GNU C++17 TESTS 40 77 1638400
107892341 tuananh238 D Feb. 19, 2021, 12:37 a.m. OK GNU C++17 TESTS 40 77 1638400
107886726 rng_71 D Feb. 18, 2021, 9:11 p.m. OK GNU C++17 TESTS 40 77 1638400
107884403 WCDI D Feb. 18, 2021, 8:20 p.m. OK GNU C++17 TESTS 39 77 1638400
107908014 19992147 D Feb. 19, 2021, 5:38 a.m. OK GNU C++17 (64) TESTS 40 46 1638400
107901972 Diegogrc D Feb. 19, 2021, 4:18 a.m. OK GNU C++17 (64) TESTS 40 46 2457600
107891267 Sakuyalove D Feb. 18, 2021, 11:46 p.m. OK GNU C++17 (64) TESTS 40 46 5529600
107898223 PaliLo D Feb. 19, 2021, 3:14 a.m. OK GNU C++17 (64) TESTS 40 61 1638400
107888671 verigo D Feb. 18, 2021, 10:07 p.m. OK GNU C++17 (64) TESTS 40 61 1638400
107872065 abhi2402 D Feb. 18, 2021, 5:54 p.m. OK GNU C++17 (64) TESTS 39 61 1638400
107869521 MarcosK D Feb. 18, 2021, 5:42 p.m. OK GNU C++17 (64) TESTS 39 61 1638400
107878859 -ILLIA- D Feb. 18, 2021, 6:58 p.m. OK GNU C++17 (64) TESTS 39 61 6451200
107907614 dblark D Feb. 19, 2021, 5:33 a.m. OK GNU C++17 (64) TESTS 40 62 1638400
107899152 DARKNlGHTS D Feb. 19, 2021, 3:30 a.m. OK GNU C++17 (64) TESTS 40 62 1638400
107884793 sersht D Feb. 18, 2021, 8:27 p.m. OK Go TESTS 39 156 819200
107890914 BlueBirdie D Feb. 18, 2021, 11:30 p.m. OK Java 11 TESTS 40 233 0
107904147 zting D Feb. 19, 2021, 4:48 a.m. OK Java 11 TESTS 40 249 0
107904079 zting D Feb. 19, 2021, 4:47 a.m. OK Java 11 TESTS 40 249 0
107900694 codefire53 D Feb. 19, 2021, 3:56 a.m. OK Java 11 TESTS 40 436 0
107869926 Dukkha D Feb. 18, 2021, 5:43 p.m. OK Java 11 TESTS 39 452 0
107893316 GennadyTran D Feb. 19, 2021, 1:13 a.m. OK Java 8 TESTS 40 186 3481600
107874055 hu_tao D Feb. 18, 2021, 6:09 p.m. OK Java 8 TESTS 39 187 3584000
107907356 RonWonWon D Feb. 19, 2021, 5:30 a.m. OK Java 8 TESTS 40 202 4403200
107870230 martins D Feb. 18, 2021, 5:44 p.m. OK Java 8 TESTS 39 218 4403200
107874386 Whiplash99 D Feb. 18, 2021, 6:12 p.m. OK Java 8 TESTS 39 233 12083200
107888341 PavelChadnov D Feb. 18, 2021, 9:56 p.m. OK Kotlin TESTS 40 264 5222400
107869502 Potassium D Feb. 18, 2021, 5:42 p.m. OK Kotlin TESTS 39 701 18841600
107896318 qwqhr D Feb. 19, 2021, 2:34 a.m. OK MS C++ 2017 TESTS 40 93 3174400
107906273 Cube219 D Feb. 19, 2021, 5:16 a.m. OK MS C++ 2017 TESTS 40 171 3174400
107891118 grey D Feb. 18, 2021, 11:39 p.m. OK MS C++ 2017 TESTS 40 187 1638400
107909863 jonitox D Feb. 19, 2021, 5:59 a.m. OK MS C++ 2017 TESTS 40 187 2457600
107892798 VClZ D Feb. 19, 2021, 12:55 a.m. OK MS C++ 2017 TESTS 40 187 32051200
107877200 Gravekper D Feb. 18, 2021, 6:40 p.m. OK MS C++ 2017 TESTS 39 202 3174400
107891417 wjli D Feb. 18, 2021, 11:54 p.m. OK MS C++ 2017 TESTS 40 1294 9011200
107891687 getN1ght D Feb. 19, 2021, 12:07 a.m. OK MS C++ 2017 TESTS 40 1746 9113600
107892134 getN1ght D Feb. 19, 2021, 12:28 a.m. OK MS C++ 2017 TESTS 40 1777 9113600
107877607 shehebe D Feb. 18, 2021, 6:44 p.m. OK PyPy 2 TESTS 39 311 18227200
107879217 reddevil100 D Feb. 18, 2021, 7:02 p.m. OK PyPy 3 TESTS 39 249 22220800
107897780 rivnam D Feb. 19, 2021, 3:06 a.m. OK PyPy 3 TESTS 40 265 23654400
107885437 nitin4184 D Feb. 18, 2021, 8:41 p.m. OK PyPy 3 TESTS 40 280 19046400
107905024 lewd D Feb. 19, 2021, 5 a.m. OK PyPy 3 TESTS 40 296 15564800
107902427 sh1194 D Feb. 19, 2021, 4:25 a.m. OK PyPy 3 TESTS 40 327 21606400
107870671 hxu10 D Feb. 18, 2021, 5:46 p.m. OK PyPy 3 TESTS 39 342 22016000
107870498 MasterKali D Feb. 18, 2021, 5:45 p.m. OK PyPy 3 TESTS 39 342 23244800
107894190 mesaliason D Feb. 19, 2021, 1:39 a.m. OK PyPy 3 TESTS 40 358 22630400
107892163 okwedook D Feb. 19, 2021, 12:29 a.m. OK PyPy 3 TESTS 40 358 22630400
107903936 srijan.sarkar D Feb. 19, 2021, 4:45 a.m. OK PyPy 3 TESTS 40 405 24268800
107871819 nwi D Feb. 18, 2021, 5:53 p.m. OK Python 2 TESTS 39 701 11161600
107901671 mkawa2 D Feb. 19, 2021, 4:14 a.m. OK Python 3 TESTS 40 1980 12800000
107902607 sh1194 D Feb. 19, 2021, 4:27 a.m. OK Python 3 TESTS 40 1981 14643200
107902715 sh1194 D Feb. 19, 2021, 4:29 a.m. OK Python 3 TESTS 40 1996 14643200
107879889 apilat D Feb. 18, 2021, 7:11 p.m. OK Rust TESTS 39 109 4812800

remove filters

Back to search problems