Testing Round 20 (Unrated, Communication Problems)

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
2168 Testing Round 20 (Unrated, Communication Problems) FINISHED False 3600 14225123 Nov. 3, 2025, 2:35 p.m.

Problems

Solved
Index
Name
Type
Tags
Community Tag
Rating
( 1541 ) B Locate PROGRAMMING binary search constructive algorithms greedy interactive

This is a run-twice (communication) interactive problem. There are two players: Player A and Player B. The jury (otherwise known as the interactor of this problem) will first interact with player A. After player A ends their interaction, the jury will interact with player B. Note that player A and player B may not directly pass information to each other; both players are only able to send information to or receive information from the jury. Before the interaction, the jury determines an integer (n) and a permutation (p)(^{\text{∗}}) of the integers from (1) to (n) exactly once. These values are consistent across both players. Player A receives the value of (n) and all elements of (p) from the jury. Then, Player A must send a binary integer (x) (that is, (x) must equal (0) or (1)) back to the jury. Player B receives the value of (n) and the integer (x) (the same integer that player A sent) from the jury. However, the permutation (p) is not given to player B. Player B's task is to determine the position of integer (n) in (p). To do so, Player B can ask the jury at most (30) queries in the following form: Choose any two integers (l) and (r) ((l \leq r)) and the jury will respond with (\max(p_{l}, p_{l+1}, \ldots, p_{r}) - \min(p_{l}, p_{l+1}, \ldots, p_{r})). Player A wants to ensure that player B can determine the position of (n). Your task is to act as both players and determine an optimal interaction strategy for both players so that player B determines the position of (n) correctly. First Run Your code will run exactly twice on each test. On the first run, you will be Player A. Input The first line of the input contains the string first . The purpose of this is so your program recognizes that this is its first run, and it should act as Player A. The second line of the input contains exactly one integer (t) — the number of test cases ((1 \le t \le 100)). The

Tutorials

Testing Round 20 Editorial (officially unofficial)

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
347276168 tddaij B Nov. 3, 2025, 3:09 p.m. OK C# 13 TESTS 14 109 1740800
347273111 fn95950 B Nov. 3, 2025, 2:57 p.m. OK C# 13 TESTS 14 124 1126400
347277053 Axoryn B Nov. 3, 2025, 3:13 p.m. OK C# 13 TESTS 14 140 307200
347347282 Manzood B Nov. 4, 2025, 4:55 a.m. OK C++17 (GCC 7-32) TESTS 14 46 102400
347283387 MonocleOfFate B Nov. 3, 2025, 3:42 p.m. OK C++17 (GCC 7-32) TESTS 14 61 102400
347289373 Code937 B Nov. 3, 2025, 4:15 p.m. OK C++17 (GCC 7-32) TESTS 14 61 16076800
347353175 PaperUmbrella B Nov. 4, 2025, 6:04 a.m. OK C++17 (GCC 7-32) TESTS 14 62 0
347350446 Shravan6398 B Nov. 4, 2025, 5:35 a.m. OK C++17 (GCC 7-32) TESTS 14 62 0
347328357 antguz B Nov. 3, 2025, 10:36 p.m. OK C++17 (GCC 7-32) TESTS 14 62 0
347316835 Aya_chino B Nov. 3, 2025, 7:28 p.m. OK C++17 (GCC 7-32) TESTS 14 62 0
347316681 JuanSign B Nov. 3, 2025, 7:26 p.m. OK C++17 (GCC 7-32) TESTS 14 62 0
347298894 SD_drago B Nov. 3, 2025, 5:12 p.m. OK C++17 (GCC 7-32) TESTS 14 62 0
347295665 Dalle2 B Nov. 3, 2025, 4:52 p.m. OK C++17 (GCC 7-32) TESTS 14 62 0
347292022 VitalyKo B Nov. 3, 2025, 4:30 p.m. OK C++20 (GCC 13-64) TESTS 14 46 0
347278736 Muhammad-Ahmad B Nov. 3, 2025, 3:20 p.m. OK C++20 (GCC 13-64) TESTS 14 46 0
347283364 nella17 B Nov. 3, 2025, 3:42 p.m. OK C++20 (GCC 13-64) TESTS 14 46 102400
347332796 gaiya13526726775 yzjznb shanyikai B Nov. 4, 2025, 12:45 a.m. OK C++20 (GCC 13-64) TESTS 14 61 0
347317950 nithish654 B Nov. 3, 2025, 7:41 p.m. OK C++20 (GCC 13-64) TESTS 14 61 0
347312804 Eshan_Karia B Nov. 3, 2025, 6:49 p.m. OK C++20 (GCC 13-64) TESTS 14 61 0
347282667 AAA-AAA-AAA B Nov. 3, 2025, 3:38 p.m. OK C++20 (GCC 13-64) TESTS 14 61 0
347279742 asnknwrk B Nov. 3, 2025, 3:24 p.m. OK C++20 (GCC 13-64) TESTS 14 61 0
347277178 Khaled_Al_Awad B Nov. 3, 2025, 3:13 p.m. OK C++20 (GCC 13-64) TESTS 14 61 0
347311085 aniketcodeforces B Nov. 3, 2025, 6:35 p.m. OK C++20 (GCC 13-64) TESTS 14 61 102400
347327189 hungchi17 B Nov. 3, 2025, 10:08 p.m. OK C++23 (GCC 14-64, msys2) TESTS 14 46 0
347289532 Filip1221 B Nov. 3, 2025, 4:16 p.m. OK C++23 (GCC 14-64, msys2) TESTS 14 46 0
347281608 ChronostasisZ B Nov. 3, 2025, 3:33 p.m. OK C++23 (GCC 14-64, msys2) TESTS 14 46 0
347273279 Top12 B Nov. 3, 2025, 2:57 p.m. OK C++23 (GCC 14-64, msys2) TESTS 14 46 0
347350102 s83757 B Nov. 4, 2025, 5:30 a.m. OK C++23 (GCC 14-64, msys2) TESTS 14 61 0
347336521 The_Moon-_- B Nov. 4, 2025, 2:11 a.m. OK C++23 (GCC 14-64, msys2) TESTS 14 61 0
347325202 Lacheck B Nov. 3, 2025, 9:28 p.m. OK C++23 (GCC 14-64, msys2) TESTS 14 61 0
347305442 HossainMohammad B Nov. 3, 2025, 5:53 p.m. OK C++23 (GCC 14-64, msys2) TESTS 14 61 0
347297085 Auchenai01 B Nov. 3, 2025, 5:01 p.m. OK C++23 (GCC 14-64, msys2) TESTS 14 61 0
347288387 mhlrmj B Nov. 3, 2025, 4:10 p.m. OK C++23 (GCC 14-64, msys2) TESTS 14 61 0
347270850 hos.lyric B Nov. 3, 2025, 2:48 p.m. OK D TESTS 14 77 2355200
347281598 1435730 B Nov. 3, 2025, 3:33 p.m. OK GNU C11 TESTS 14 93 8294400
347275129 pengin_2000 B Nov. 3, 2025, 3:05 p.m. OK GNU C11 TESTS 14 108 8396800
347332574 0x3F B Nov. 4, 2025, 12:38 a.m. OK Go TESTS 14 62 307200
347283689 owi8270 B Nov. 3, 2025, 3:44 p.m. OK Go TESTS 14 62 307200
347332803 0x3F B Nov. 4, 2025, 12:45 a.m. OK Go TESTS 14 93 819200
347337998 shreyashdhumal B Nov. 4, 2025, 2:38 a.m. OK Java 21 TESTS 14 281 1024000
347327496 sahasrad B Nov. 3, 2025, 10:14 p.m. OK Java 21 TESTS 14 327 716800
347330296 ysahu B Nov. 3, 2025, 11:35 p.m. OK Java 21 TESTS 14 327 1126400
347274828 nikhilsingh_21 B Nov. 3, 2025, 3:03 p.m. OK Java 21 TESTS 14 359 921600
347292613 keshav_.agg B Nov. 3, 2025, 4:33 p.m. OK Java 21 TESTS 14 359 1331200
347278335 Balu2907 B Nov. 3, 2025, 3:18 p.m. OK Java 21 TESTS 14 421 1433600
347293927 SoMeQuit B Nov. 3, 2025, 4:41 p.m. OK Java 8 TESTS 14 171 0
347270011 roshankumar4567 B Nov. 3, 2025, 2:45 p.m. OK Java 8 TESTS 14 233 0
347281193 testtest111ksjfrdvn B Nov. 3, 2025, 3:31 p.m. OK Java 8 TESTS 14 327 15257600
347269498 arvindf232 B Nov. 3, 2025, 2:44 p.m. OK Kotlin 2.2 TESTS 14 249 1843200
347322966 stan23456 B Nov. 3, 2025, 8:49 p.m. OK PyPy 3-64 TESTS 14 108 2252800
347280194 liar3743 B Nov. 3, 2025, 3:26 p.m. OK PyPy 3-64 TESTS 14 109 2150400
347273841 teekaytai B Nov. 3, 2025, 2:59 p.m. OK PyPy 3-64 TESTS 14 109 2252800
347272788 bribritt B Nov. 3, 2025, 2:55 p.m. OK PyPy 3-64 TESTS 14 109 2252800
347327445 VaHiX B Nov. 3, 2025, 10:13 p.m. OK PyPy 3-64 TESTS 14 124 2252800
347297815 fatalerror B Nov. 3, 2025, 5:05 p.m. OK PyPy 3-64 TESTS 14 124 2252800
347276561 shubham6105 B Nov. 3, 2025, 3:11 p.m. OK PyPy 3-64 TESTS 14 124 2252800
347349709 tequila_sunrise B Nov. 4, 2025, 5:26 a.m. OK PyPy 3-64 TESTS 14 124 2969600
347283658 Mukundan314 B Nov. 3, 2025, 3:43 p.m. OK PyPy 3-64 TESTS 14 125 2150400
347315434 ChatIsThisReal B Nov. 3, 2025, 7:14 p.m. OK PyPy 3-64 TESTS 14 139 3481600
347271578 zarinaabsaliamova B Nov. 3, 2025, 2:51 p.m. OK Python 3 TESTS 14 108 1536000
347342250 Spheniscine B Nov. 4, 2025, 3:40 a.m. OK Rust 2021 TESTS 14 77 0
347316308 Svlad_Cjelli B Nov. 3, 2025, 7:22 p.m. OK Rust 2024 TESTS 14 62 0
347279634 micronc B Nov. 3, 2025, 3:24 p.m. OK Rust 2024 TESTS 14 62 0
347271561 null_lambda B Nov. 3, 2025, 2:51 p.m. OK Rust 2024 TESTS 14 62 0
347273159 Dilha_1526 B Nov. 3, 2025, 2:57 p.m. OK Rust 2024 TESTS 14 62 102400
347306048 pradeep027 B Nov. 3, 2025, 5:58 p.m. OK Rust 2024 TESTS 14 77 102400
347273315 Egor B Nov. 3, 2025, 2:57 p.m. OK Rust 2024 TESTS 14 93 102400

remove filters

Back to search problems