2020-2021 ICPC, NERC, Southern and Volga Russian Regional Contest (Online Mirror, ICPC Rules)

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
1468 2020-2021 ICPC, NERC, Southern and Volga Russian Regional Contest (Online Mirror, ICPC Rules) FINISHED False 18000 128370263 Dec. 25, 2020, 11:35 a.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 4810 ) D Firecrackers PROGRAMMING binary search sortings

B"Consider a long corridor which can be divided into n square cells of size 1 x 1 . These cells are numbered from 1 to n from left to right. There are two people in this corridor, a hooligan and a security guard. Initially, the hooligan is in the a -th cell, the guard is in the b -th cell ( a ne b ). There are m firecrackers in the hooligan's pocket, the i -th firecracker explodes in s_i seconds after being lit. The following events happen each second (sequentially, exactly in the following order): Obviously, the hooligan will be caught sooner or later, since the corridor is finite. His goal is to see the maximum number of firecrackers explode before he is caught; that is, he will act in order to maximize the number of firecrackers that explodes before he is caught. Your task is to calculate the number of such firecrackers, if the hooligan acts optimally. The first line contains one integer t ( 1 <= t <= 1000 ) -- the number of test cases. Each test case consists of two lines. The first line contains four integers n , m , a and b ( 2 <= n <= 10^9 ; 1 <= m <= 2 cdot 10^5 ; 1 <= a, b <= n ; a ne b ) -- the size of the corridor, the number of firecrackers, the initial location of the hooligan and the initial location of the guard, respectively. The second line contains m integers s_1 , s_2 , ..., s_m ( 1 <= s_i <= 10^9 ), where s_i is the time it takes the i -th firecracker to explode after it is lit. It is guaranteed that the sum of m over all test cases does not exceed 2 cdot 10^5 . For each test case, print one integer -- the maximum number of firecrackers that the hooligan can explode before he is caught. In the first test case, the hooligan should act, for example, as follows: "...

Tutorials

Tutorial (PDF)

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
102326544 RingweEH D Dec. 25, 2020, 2:46 p.m. OK GNU C++11 TESTS 85 46 614400
102311784 C20192413 Lucky_Glass D Dec. 25, 2020, 12:48 p.m. OK GNU C++11 TESTS 85 46 614400
102312102 qwqdeco Juanzhang yijan D Dec. 25, 2020, 12:50 p.m. OK GNU C++11 TESTS 85 46 819200
102309964 cbio AzusaCat hs-black D Dec. 25, 2020, 12:34 p.m. OK GNU C++11 TESTS 85 46 819200
102308134 xzx34 zlt1117 Yukikaze_ D Dec. 25, 2020, 12:20 p.m. OK GNU C++11 TESTS 85 46 819200
102321044 RealMikeDuke jzp chr_ D Dec. 25, 2020, 2:02 p.m. OK GNU C++11 TESTS 85 46 1228800
102315979 KGX2020 jzqjzq get_r_ight D Dec. 25, 2020, 1:20 p.m. OK GNU C++11 TESTS 85 46 1228800
102311851 wefvdge sunyuhan1998 Zechariah_2001 D Dec. 25, 2020, 12:48 p.m. OK GNU C++11 TESTS 85 46 2048000
102306971 i_m_a D Dec. 25, 2020, 12:11 p.m. OK GNU C++11 TESTS 85 46 3788800
102314638 silly-1-2-3 zswzswzswzsw BQAC D Dec. 25, 2020, 1:10 p.m. OK GNU C++11 TESTS 85 46 8089600
102330439 maxw D Dec. 25, 2020, 3:19 p.m. OK GNU C++14 TESTS 85 78 819200
102327590 mikechan D Dec. 25, 2020, 2:55 p.m. OK GNU C++14 TESTS 85 78 819200
102313409 AkaiLemon D Dec. 25, 2020, 1 p.m. OK GNU C++14 TESTS 85 78 819200
102314714 skarlord harsh290198 Addy D Dec. 25, 2020, 1:11 p.m. OK GNU C++14 TESTS 85 78 1638400
102312463 lavenderwithbluish AquaMoon D Dec. 25, 2020, 12:53 p.m. OK GNU C++14 TESTS 85 78 3993600
102322905 jaewoo2009 D Dec. 25, 2020, 2:17 p.m. OK GNU C++14 TESTS 85 92 819200
102363476 Mr.Doap D Dec. 26, 2020, 3:58 a.m. OK GNU C++14 TESTS 85 93 819200
102360604 sped7 D Dec. 26, 2020, 2:06 a.m. OK GNU C++14 TESTS 85 93 819200
102336147 Ely_9696 prankami Moen1578 D Dec. 25, 2020, 4:15 p.m. OK GNU C++14 TESTS 85 93 819200
102333242 Drice D Dec. 25, 2020, 3:44 p.m. OK GNU C++14 TESTS 85 93 819200
102316619 _Backl1ght D Dec. 25, 2020, 1:26 p.m. OK GNU C++17 TESTS 85 46 2252800
102319967 Hyperbolic D Dec. 25, 2020, 1:53 p.m. OK GNU C++17 TESTS 85 77 819200
102323319 boocoo D Dec. 25, 2020, 2:20 p.m. OK GNU C++17 TESTS 85 78 819200
102320575 Aphelios D Dec. 25, 2020, 1:58 p.m. OK GNU C++17 TESTS 85 78 819200
102318302 PhanTrinh chemthan D Dec. 25, 2020, 1:39 p.m. OK GNU C++17 TESTS 85 78 819200
102322647 bazzyadb hg333 D Dec. 25, 2020, 2:15 p.m. OK GNU C++17 TESTS 85 78 211763200
102324662 idk321 D Dec. 25, 2020, 2:31 p.m. OK GNU C++17 TESTS 85 92 819200
102316648 Gankutsuou WhiteChocolate ali.zine D Dec. 25, 2020, 1:26 p.m. OK GNU C++17 TESTS 85 92 819200
102368641 Monkey_de_Luffy D Dec. 26, 2020, 6:01 a.m. OK GNU C++17 TESTS 85 93 819200
102368609 Cuber999 bill_lin D Dec. 26, 2020, 6 a.m. OK GNU C++17 TESTS 85 93 819200
102311325 axat0081 D Dec. 25, 2020, 12:44 p.m. OK GNU C++17 (64) TESTS 85 46 4710400
102308480 QAQAutoMaton PinkRabbit D Dec. 25, 2020, 12:23 p.m. OK GNU C++17 (64) TESTS 85 46 5017600
102344633 magnus.hegdahl D Dec. 25, 2020, 6:28 p.m. OK GNU C++17 (64) TESTS 85 46 20889600
102330514 CosminMorar D Dec. 25, 2020, 3:20 p.m. OK GNU C++17 (64) TESTS 85 62 819200
102316431 invi12 H4XX mintCHILL D Dec. 25, 2020, 1:24 p.m. OK GNU C++17 (64) TESTS 85 62 819200
102313219 KhaledRezk D Dec. 25, 2020, 12:58 p.m. OK GNU C++17 (64) TESTS 85 62 819200
102311999 N_o_o_B D Dec. 25, 2020, 12:49 p.m. OK GNU C++17 (64) TESTS 85 62 819200
102311538 seastar105 semteo04 shiftpsh D Dec. 25, 2020, 12:45 p.m. OK GNU C++17 (64) TESTS 85 62 819200
102310170 T-R Thallium_is_Vegetable D Dec. 25, 2020, 12:35 p.m. OK GNU C++17 (64) TESTS 85 62 819200
102309954 Raiden steinum YouKn0wWho D Dec. 25, 2020, 12:34 p.m. OK GNU C++17 (64) TESTS 85 62 819200
102329558 sf14t D Dec. 25, 2020, 3:12 p.m. OK Java 11 TESTS 85 249 0
102354519 soumit915 D Dec. 25, 2020, 9:34 p.m. OK Java 11 TESTS 85 264 4505600
102316542 insert_cool_handle D Dec. 25, 2020, 1:25 p.m. OK Java 11 TESTS 85 280 1638400
102316122 chris_11 D Dec. 25, 2020, 1:21 p.m. OK Java 11 TESTS 85 311 20070400
102325157 rithyKabir ineffablekenobi hasib_hossain D Dec. 25, 2020, 2:35 p.m. OK Java 8 TESTS 85 155 0
102309392 DishonoredRighteous iakovlev.zakhar golikovnik D Dec. 25, 2020, 12:30 p.m. OK Java 8 TESTS 85 171 11980800
102321568 present_sir PRIYANSH_TOMAR rachitpts.2454 D Dec. 25, 2020, 2:06 p.m. OK Java 8 TESTS 85 202 11980800
102328413 nitin_codr sudhanshu_lucky D Dec. 25, 2020, 3:02 p.m. OK Java 8 TESTS 85 202 12288000
102365793 godxpunk D Dec. 26, 2020, 5:04 a.m. OK Java 8 TESTS 85 265 13721600
102319093 hruif D Dec. 25, 2020, 1:46 p.m. OK MS C++ 2017 TESTS 85 234 819200
102350635 Gravekper D Dec. 25, 2020, 8:04 p.m. OK MS C++ 2017 TESTS 85 249 2048000
102360217 kagu D Dec. 26, 2020, 1:50 a.m. OK PyPy 2 TESTS 85 202 12800000
102323009 wow_ok FlakeLCR conqueror_of_tourist D Dec. 25, 2020, 2:18 p.m. OK PyPy 3 TESTS 85 233 19456000
102350862 silvertint D Dec. 25, 2020, 8:08 p.m. OK PyPy 3 TESTS 85 358 18022400
102311012 Mahipalkeizer yash_chad D Dec. 25, 2020, 12:41 p.m. OK PyPy 3 TESTS 85 358 21094400
102368142 pedastrian57 D Dec. 26, 2020, 5:52 a.m. OK PyPy 3 TESTS 85 358 83353600
102315147 SPD_9X2 D Dec. 25, 2020, 1:14 p.m. OK PyPy 3 TESTS 85 373 18534400
102309817 semjon.00 Crisp0r Pneumokogur8 D Dec. 25, 2020, 12:33 p.m. OK PyPy 3 TESTS 85 389 16691200
102312975 karthikeya619 alphatron99 Kishen19 D Dec. 25, 2020, 12:56 p.m. OK PyPy 3 TESTS 85 389 17817600
102333433 Bhagi069 D Dec. 25, 2020, 3:46 p.m. OK PyPy 3 TESTS 85 420 19046400
102333386 Cheval_Gauvin D Dec. 25, 2020, 3:45 p.m. OK PyPy 3 TESTS 85 420 19046400
102322797 TML104 510030805voidf D Dec. 25, 2020, 2:16 p.m. OK PyPy 3 TESTS 85 420 19046400
102350576 sh1194 D Dec. 25, 2020, 8:03 p.m. OK Python 3 TESTS 85 389 18329600
102345624 code_code_code D Dec. 25, 2020, 6:42 p.m. OK Python 3 TESTS 85 405 17510400
102336968 bharat_biradar D Dec. 25, 2020, 4:25 p.m. OK Python 3 TESTS 85 405 18329600
102308701 sansen D Dec. 25, 2020, 12:24 p.m. OK Rust TESTS 85 62 6348800
102293707 D Dec. 25, 2020, 9:38 a.m. OK Unknown TESTS 0 0 0
102293635 D Dec. 25, 2020, 9:38 a.m. OK Unknown TESTS 0 0 0
102293463 D Dec. 25, 2020, 9:38 a.m. OK Unknown TESTS 0 0 0
102293446 D Dec. 25, 2020, 9:38 a.m. OK Unknown TESTS 0 0 0

remove filters

Back to search problems