Codeforces Global Round 24

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
1764 Codeforces Global Round 24 FINISHED False 9000 67794863 Nov. 26, 2022, 2:05 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 543 ) G2 Doremy's Perfect DS Class (Medium Version) PROGRAMMING binary search interactive

B'The only difference between this problem and the other two versions is the maximum number of queries. In this version, you are allowed to ask at most mathbf{25} queries. You can make hacks only if all versions of the problem are solved. This is an interactive problem. "Everybody! Doremy 's Perfect Data Structure Class is about to start! Come and do your best if you want to have as much IQ as me!" In today 's Data Structure class, Doremy is teaching everyone a powerful data structure -- Doremy tree! Now she gives you a quiz to prove that you are paying attention in class. Given an array a of length m , Doremy tree supports the query Q(l,r,k) , where 1 <= q l <= q r <= q m and 1 <= q k <= q m , which returns the number of distinct integers in the array <= ft[ lfloor frac{a_l}{k} rfloor, lfloor frac{a_{l+1}}{k} rfloor, ldots, lfloor frac{a_r}{k} rfloor right] . Doremy has a secret permutation p of integers from 1 to n . You can make queries, in one query, you give 3 integers l,r,k ( 1 <= q l <= q r <= q n , 1 <= q k <= q n ) and receive the value of Q(l,r,k) for the array p . Can you find the index y ( 1 <= q y <= q n ) such that p_y=1 in at most mathbf{25} queries? Note that the permutation p is fixed before any queries are made. You begin the interaction by reading an integer n ( 3 <= n <= 1024 ) in the first line -- the length of the permutation. To make a query, you should output To give the answer, you should output After printing a query or the answer, do not forget to output the end of line and flush the output. Otherwise, you will get Idleness limit exceeded. To do this, use: Hacks Format The first line of the hack contains an integer n ( 3 <= n <= 1024 ) -- the length of the permutation. The second line of the hack contains n distinct integers p_1,p_2, ldots,p_n ( 1 <= p_i <= n ) xe2'...

Tutorials

Codeforces Global Round 24 Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
182702291 hos.lyric G2 Nov. 26, 2022, 5:03 p.m. OK D TESTS 66 15 0
182718331 Gassa G2 Nov. 26, 2022, 7:56 p.m. OK D TESTS 66 30 204800
182715791 Gassa G2 Nov. 26, 2022, 7:18 p.m. OK D TESTS 66 31 0
182714368 Gassa G2 Nov. 26, 2022, 7 p.m. OK D TESTS 66 31 0
182696360 rainboy G2 Nov. 26, 2022, 4:20 p.m. OK GNU C11 TESTS 66 30 0
182698811 dlalswp25 G2 Nov. 26, 2022, 4:31 p.m. OK GNU C++14 TESTS 66 15 0
182697173 Sol1 G2 Nov. 26, 2022, 4:24 p.m. OK GNU C++14 TESTS 66 15 0
182694754 tomerun G2 Nov. 26, 2022, 4:12 p.m. OK GNU C++14 TESTS 66 15 0
182697512 liuhengxi G2 Nov. 26, 2022, 4:26 p.m. OK GNU C++14 TESTS 66 15 0
182740961 m1979823301m G2 Nov. 27, 2022, 5:14 a.m. OK GNU C++14 TESTS 66 15 0
182683495 chuochuo G2 Nov. 26, 2022, 3:22 p.m. OK GNU C++14 TESTS 66 15 307200
182692295 emptyhope G2 Nov. 26, 2022, 4 p.m. OK GNU C++14 TESTS 66 31 9932800
182706798 Agreb G2 Nov. 26, 2022, 5:41 p.m. OK GNU C++17 TESTS 66 15 0
182706616 dmenezes G2 Nov. 26, 2022, 5:39 p.m. OK GNU C++17 TESTS 66 15 0
182706476 dmenezes G2 Nov. 26, 2022, 5:38 p.m. OK GNU C++17 TESTS 66 15 0
182703214 Dhruvil_Kakadiya G2 Nov. 26, 2022, 5:10 p.m. OK GNU C++17 TESTS 66 15 0
182699690 Miracle0viiiiiv G2 Nov. 26, 2022, 4:34 p.m. OK GNU C++17 TESTS 66 15 0
182699286 chaeyihwan G2 Nov. 26, 2022, 4:33 p.m. OK GNU C++17 TESTS 66 15 0
182697993 A_Fan_of_the_AK_King--lk G2 Nov. 26, 2022, 4:28 p.m. OK GNU C++17 TESTS 66 15 0
182694405 ugly2333 G2 Nov. 26, 2022, 4:11 p.m. OK GNU C++17 TESTS 66 15 0
182693949 GoRed G2 Nov. 26, 2022, 4:09 p.m. OK GNU C++17 TESTS 66 15 0
182742635 emonzhong G2 Nov. 27, 2022, 5:42 a.m. OK GNU C++17 TESTS 66 15 0
182682579 Sana G2 Nov. 26, 2022, 3:18 p.m. OK GNU C++17 (64) TESTS 66 15 0
182718516 Benq G2 Nov. 26, 2022, 7:59 p.m. OK GNU C++17 (64) TESTS 66 15 0
182702812 Rafbill G2 Nov. 26, 2022, 5:07 p.m. OK GNU C++17 (64) TESTS 66 15 0
182698689 duality G2 Nov. 26, 2022, 4:30 p.m. OK GNU C++17 (64) TESTS 66 15 0
182696075 Nyaan G2 Nov. 26, 2022, 4:19 p.m. OK GNU C++17 (64) TESTS 66 15 0
182695682 p_b_p_b G2 Nov. 26, 2022, 4:17 p.m. OK GNU C++17 (64) TESTS 66 15 0
182695106 neal G2 Nov. 26, 2022, 4:14 p.m. OK GNU C++17 (64) TESTS 66 15 0
182697446 yosupo G2 Nov. 26, 2022, 4:25 p.m. OK GNU C++17 (64) TESTS 66 15 102400
182697255 353cerega G2 Nov. 26, 2022, 4:24 p.m. OK GNU C++17 (64) TESTS 66 15 307200
182694665 QAQAutoMaton G2 Nov. 26, 2022, 4:12 p.m. OK GNU C++17 (64) TESTS 66 15 5017600
182737054 suyiheng G2 Nov. 27, 2022, 3:47 a.m. OK GNU C++20 (64) TESTS 66 15 0
182736919 feecIe6418 G2 Nov. 27, 2022, 3:44 a.m. OK GNU C++20 (64) TESTS 66 15 0
182736650 dragonslayerintraining G2 Nov. 27, 2022, 3:37 a.m. OK GNU C++20 (64) TESTS 66 15 0
182735087 dragonslayerintraining G2 Nov. 27, 2022, 2:53 a.m. OK GNU C++20 (64) TESTS 66 15 0
182734892 dragonslayerintraining G2 Nov. 27, 2022, 2:47 a.m. OK GNU C++20 (64) TESTS 66 15 0
182734834 dragonslayerintraining G2 Nov. 27, 2022, 2:46 a.m. OK GNU C++20 (64) TESTS 66 15 0
182733014 dreamoon_love_AA G2 Nov. 27, 2022, 1:51 a.m. OK GNU C++20 (64) TESTS 66 15 0
182736036 wery0 G2 Nov. 27, 2022, 3:21 a.m. OK GNU C++20 (64) TESTS 66 15 0
182742011 liaopengfei G2 Nov. 27, 2022, 5:31 a.m. OK GNU C++20 (64) TESTS 66 15 0
182738985 crescent_yhw G2 Nov. 27, 2022, 4:32 a.m. OK GNU C++20 (64) TESTS 66 15 0
182690201 Tlatoani G2 Nov. 26, 2022, 3:51 p.m. OK Kotlin 1.6 TESTS 66 249 0
182693521 amenotiomoi G2 Nov. 26, 2022, 4:06 p.m. OK PyPy 3-64 TESTS 66 77 0

remove filters

Back to search problems