Educational Codeforces Round 93 (Rated for 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
1398 Educational Codeforces Round 93 (Rated for Div. 2) FINISHED False 7200 139937111 Aug. 14, 2020, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 1133 ) G Running Competition PROGRAMMING bitmasks fft math number theory

B"A running competition is going to be held soon. The stadium where the competition will be held can be represented by several segments on the coordinate plane: For example, here is a picture of the stadium with x = 10 , y = 5 , n = 3 and a = [0, 3, 5, 10] : A lap is a route that goes along the segments, starts and finishes at the same point, and never intersects itself (the only two points of a lap that coincide are its starting point and ending point). The length of a lap is a total distance travelled around it. For example, the red route in the picture representing the stadium is a lap of length 24 . The competition will be held in q stages. The i -th stage has length l_i , and the organizers want to choose a lap for each stage such that the length of the lap is a divisor of l_i . The organizers don't want to choose short laps for the stages, so for each stage, they want to find the maximum possible length of a suitable lap. Help the organizers to calculate the maximum possible lengths of the laps for the stages! In other words, for every l_i , find the maximum possible integer L such that l_i bmod L = 0 , and there exists a lap of length exactly L . If it is impossible to choose such a lap then print -1 . The first line contains three integers n , x and y ( 1 <= n, x, y <= 2 cdot 10^5 , n <= x ). The second line contains n + 1 integers a_0 , a_1 , ..., a_n ( 0 = a_0 < a_1 < a_2 < ... < a_{n - 1} < a_n = x ). The third line contains one integer q ( 1 <= q <= 2 cdot 10^5 ) -- the number of stages. The fourth line contains q even integers l_1 , l_2 , ..., l_q ( 4 <= l_i <= 10^6 ) -- the lengths of the stages. Print q numbers. The i -th number should be equal to the maximum possible length of a suitable lap for the i -th stage, or -1 if it is impossible to choos"...

Tutorials

Educational Codeforces Round 93 Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
91438925 sslotin G Aug. 30, 2020, 8:38 p.m. OK D TESTS 73 639 96358400
91031571 daidao G Aug. 26, 2020, 8:15 a.m. OK GNU C++11 TESTS 73 249 57344000
91023263 daidao G Aug. 26, 2020, 6:23 a.m. OK GNU C++11 TESTS 73 280 39731200
90842026 daidao G Aug. 24, 2020, 3:58 p.m. OK GNU C++11 TESTS 73 295 57344000
90512874 Zars19 G Aug. 21, 2020, 8 a.m. OK GNU C++11 TESTS 73 296 40243200
90200920 4790iop G Aug. 17, 2020, 6:38 a.m. OK GNU C++11 TESTS 73 296 62054400
91470542 froggyzhang G Aug. 31, 2020, 7:56 a.m. OK GNU C++11 TESTS 73 311 17408000
90268758 liberShip G Aug. 18, 2020, 12:59 a.m. OK GNU C++11 TESTS 73 311 31129600
90824762 jgy002 G Aug. 24, 2020, 12:24 p.m. OK GNU C++11 TESTS 73 374 64204800
90622417 Prabowo G Aug. 21, 2020, 5:27 p.m. OK GNU C++11 TESTS 73 483 45977600
91052958 huanggs G Aug. 26, 2020, 12:55 p.m. OK GNU C++11 TESTS 73 498 54681600
90495141 Orz_c---8 G Aug. 20, 2020, 8:37 p.m. OK GNU C++14 TESTS 73 249 46182400
90495078 Orz_c---8 G Aug. 20, 2020, 8:36 p.m. OK GNU C++14 TESTS 73 280 50380800
90495166 Orz_c---8 G Aug. 20, 2020, 8:38 p.m. OK GNU C++14 TESTS 73 311 46182400
91264340 K0u1e G Aug. 29, 2020, 7:22 a.m. OK GNU C++14 TESTS 73 405 10547200
90474680 mahdi.hasnat G Aug. 20, 2020, 3:10 p.m. OK GNU C++14 TESTS 73 405 25702400
90673323 siddhugzp G Aug. 22, 2020, 9:11 a.m. OK GNU C++14 TESTS 73 405 27750400
91699028 __Wind__ G Sept. 3, 2020, 8:08 a.m. OK GNU C++14 TESTS 73 421 54784000
91161496 CheckCheck007 G Aug. 27, 2020, 6:43 p.m. OK GNU C++14 TESTS 73 498 38809600
91693983 Willem G Sept. 3, 2020, 6:52 a.m. OK GNU C++14 TESTS 73 498 76185600
91696594 Willem G Sept. 3, 2020, 7:33 a.m. OK GNU C++14 TESTS 73 514 76185600
91530917 changez G Sept. 1, 2020, 2:07 a.m. OK GNU C++17 TESTS 73 265 55296000
90289533 jiangly G Aug. 18, 2020, 8:18 a.m. OK GNU C++17 TESTS 73 295 12288000
90228055 idsigma G Aug. 17, 2020, 12:37 p.m. OK GNU C++17 TESTS 73 295 23859200
91530942 changez G Sept. 1, 2020, 2:08 a.m. OK GNU C++17 TESTS 73 311 55296000
90248735 john_709 G Aug. 17, 2020, 4:36 p.m. OK GNU C++17 TESTS 73 342 44339200
90261496 Radewoosh G Aug. 17, 2020, 8:13 p.m. OK GNU C++17 TESTS 73 436 32563200
90686202 ceerRep G Aug. 22, 2020, 12:16 p.m. OK GNU C++17 TESTS 73 451 45568000
90377741 gs15120 G Aug. 19, 2020, 10:03 a.m. OK GNU C++17 TESTS 73 452 39321600
90899012 Fliahin G Aug. 25, 2020, 12:30 p.m. OK GNU C++17 TESTS 73 483 189849600
90483584 abeker G Aug. 20, 2020, 5 p.m. OK GNU C++17 TESTS 73 514 89497600
90416555 kessido G Aug. 19, 2020, 7:17 p.m. OK GNU C++17 (64) TESTS 73 155 16793600
90416773 kessido G Aug. 19, 2020, 7:21 p.m. OK GNU C++17 (64) TESTS 73 155 19251200
90418915 kessido G Aug. 19, 2020, 8:15 p.m. OK GNU C++17 (64) TESTS 73 171 22630400
90410518 hello_codeforces G Aug. 19, 2020, 5:29 p.m. OK GNU C++17 (64) TESTS 73 186 11673600
90410860 hello_codeforces G Aug. 19, 2020, 5:35 p.m. OK GNU C++17 (64) TESTS 73 202 11673600
90305509 Siberian G Aug. 18, 2020, 12:05 p.m. OK GNU C++17 (64) TESTS 73 233 17715200
90305459 Siberian G Aug. 18, 2020, 12:04 p.m. OK GNU C++17 (64) TESTS 73 280 17715200
90417854 kessido G Aug. 19, 2020, 7:47 p.m. OK GNU C++17 (64) TESTS 73 296 40550400
90314608 Renaats G Aug. 18, 2020, 2:05 p.m. OK GNU C++17 (64) TESTS 73 326 74854400
90417022 kessido G Aug. 19, 2020, 7:27 p.m. OK GNU C++17 (64) TESTS 73 327 12800000
90440572 liouzhou_101 G Aug. 20, 2020, 7:06 a.m. OK Java 11 TESTS 73 592 10240000
90440132 liouzhou_101 G Aug. 20, 2020, 7 a.m. OK Java 11 TESTS 73 966 10240000
90353341 PizzaLovers007 G Aug. 19, 2020, 2:56 a.m. OK Java 11 TESTS 73 1887 44953600
90479269 liouzhou_101 G Aug. 20, 2020, 4:04 p.m. OK Java 8 TESTS 73 452 10342400
90440559 liouzhou_101 G Aug. 20, 2020, 7:06 a.m. OK Java 8 TESTS 73 467 7987200
90513061 liouzhou_101 G Aug. 21, 2020, 8:03 a.m. OK Java 8 TESTS 73 483 28876800
90513001 liouzhou_101 G Aug. 21, 2020, 8:02 a.m. OK Java 8 TESTS 73 483 28876800
90513152 liouzhou_101 G Aug. 21, 2020, 8:04 a.m. OK Java 8 TESTS 73 514 28876800
90504147 liouzhou_101 G Aug. 21, 2020, 3:48 a.m. OK Java 8 TESTS 73 561 28876800
90440172 liouzhou_101 G Aug. 20, 2020, 7:01 a.m. OK Java 8 TESTS 73 842 9523200

remove filters

Back to search problems