Codeforces Round 878 (Div. 3)

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
1840 Codeforces Round 878 (Div. 3) FINISHED False 8100 51204263 June 6, 2023, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 2444 ) G1 In Search of Truth (Easy Version) PROGRAMMING brute force constructive algorithms interactive math probabilities

B'The only difference between easy and hard versions is the maximum number of queries. In this version, you are allowed to ask at most 2023 queries. This is an interactive problem. You are playing a game. The circle is divided into n sectors, sectors are numbered from 1 to n in some order. You are in the adjacent room and do not know either the number of sectors or their numbers. There is also an arrow that initially points to some sector. Initially, the host tells you the number of the sector to which the arrow points. After that, you can ask the host to move the arrow k sectors counterclockwise or clockwise at most 2023 times. And each time you are told the number of the sector to which the arrow points. Your task is to determine the integer n -- the number of sectors in at most 2023 queries. It is guaranteed that 1 <= n <= 10^6 . The input consists of a single integer x ( 1 <= x <= n ) -- the number of the initial sector. After you determine the integer n -- the number of sectors, you should output "! n" ( 1 <= n <= 10^6 ). After that the program should immediately terminate. Note that, printing the answer does not count as a query. It is guaranteed that the integer n and the numbers of the sectors are fixed initially and will not be changed by the jury program depending on the queries. After reading the description of the input, you may ask queries. Queries can be of two types: After each query, you should read an integer x ( 1 <= x <= n ) -- the number of the current sector to which the arrow points. You are allowed to make at most 2023 queries in total. If you make too many queries, you will get Wrong answer. After printing a query or the answer, do not forget to output a the end of line and flush the output. Otherwise, you will get Idleness limit exceeded. To do this, use: Hacks To hack, use the following test format. In the first line, outp'...

Tutorials

Codeforces Round #878 (Div.3) Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
208850342 Hritik12 G1 June 7, 2023, 4:07 a.m. OK GNU C++14 TESTS 136 31 204800
208839298 ayman01287985950 G1 June 6, 2023, 11:33 p.m. OK GNU C++14 TESTS 136 31 204800
208846033 why_123 G1 June 7, 2023, 2:50 a.m. OK GNU C++14 TESTS 136 31 8806400
208816805 changzhou G1 June 6, 2023, 5:14 p.m. OK GNU C++14 TESTS 136 46 0
208816365 zzz_xx G1 June 6, 2023, 5:11 p.m. OK GNU C++14 TESTS 136 46 0
208857338 nuistdzq G1 June 7, 2023, 5:54 a.m. OK GNU C++14 TESTS 136 46 204800
208856127 Mohithkk G1 June 7, 2023, 5:37 a.m. OK GNU C++14 TESTS 136 46 204800
208852631 lasventuras G1 June 7, 2023, 4:44 a.m. OK GNU C++14 TESTS 136 46 204800
208850870 ajaman190 G1 June 7, 2023, 4:15 a.m. OK GNU C++14 TESTS 136 46 204800
208848062 linlexiao G1 June 7, 2023, 3:27 a.m. OK GNU C++14 TESTS 136 46 204800
208830947 ikaurov G1 June 6, 2023, 7:48 p.m. OK GNU C++17 TESTS 136 15 204800
208816418 BloCamLimb G1 June 6, 2023, 5:12 p.m. OK GNU C++17 TESTS 136 15 204800
208831076 yellowtomato98 G1 June 6, 2023, 7:50 p.m. OK GNU C++17 TESTS 136 31 0
208817904 stcmuyi G1 June 6, 2023, 5:21 p.m. OK GNU C++17 TESTS 136 31 3993600
208832514 Cai_Guang G1 June 6, 2023, 8:15 p.m. OK GNU C++17 TESTS 136 31 74649600
208849875 SANYASI_RAJA G1 June 7, 2023, 3:59 a.m. OK GNU C++17 TESTS 136 46 0
208841810 drastic G1 June 7, 2023, 1:14 a.m. OK GNU C++17 TESTS 136 46 0
208837011 sussy__baka G1 June 6, 2023, 10:09 p.m. OK GNU C++17 TESTS 136 46 0
208816904 Undying G1 June 6, 2023, 5:15 p.m. OK GNU C++17 TESTS 136 46 0
208857755 Mourya07 G1 June 7, 2023, 6 a.m. OK GNU C++17 TESTS 136 46 204800
208850664 Mateo.Noel G1 June 7, 2023, 4:12 a.m. OK GNU C++17 (64) TESTS 136 31 0
208844301 enslaved G1 June 7, 2023, 2:16 a.m. OK GNU C++17 (64) TESTS 136 31 0
208814426 MaGnsi0 G1 June 6, 2023, 5 p.m. OK GNU C++17 (64) TESTS 136 31 0
208845393 gqf123 G1 June 7, 2023, 2:37 a.m. OK GNU C++17 (64) TESTS 136 31 3993600
208848248 Sohith_14 G1 June 7, 2023, 3:30 a.m. OK GNU C++17 (64) TESTS 136 46 102400
208843836 MattTheNub G1 June 7, 2023, 2:05 a.m. OK GNU C++17 (64) TESTS 136 46 102400
208837857 TheScrasse G1 June 6, 2023, 10:36 p.m. OK GNU C++17 (64) TESTS 136 46 102400
208812924 fiire_ice G1 June 6, 2023, 4:54 p.m. OK GNU C++17 (64) TESTS 136 46 102400
208811195 dominik-korsa G1 June 6, 2023, 4:49 p.m. OK GNU C++17 (64) TESTS 136 46 102400
208845564 Once_I_Liked_AGirl G1 June 7, 2023, 2:40 a.m. OK GNU C++17 (64) TESTS 136 46 204800
208818939 Joler_ G1 June 6, 2023, 5:29 p.m. OK GNU C++20 (64) TESTS 136 30 0
208816150 Boboge G1 June 6, 2023, 5:10 p.m. OK GNU C++20 (64) TESTS 136 30 0
208812444 ZrjaK G1 June 6, 2023, 4:53 p.m. OK GNU C++20 (64) TESTS 136 30 307200
208857191 StarSilk G1 June 7, 2023, 5:52 a.m. OK GNU C++20 (64) TESTS 136 31 0
208856487 jiangly G1 June 7, 2023, 5:43 a.m. OK GNU C++20 (64) TESTS 136 31 0
208856020 Geobiyye G1 June 7, 2023, 5:36 a.m. OK GNU C++20 (64) TESTS 136 31 0
208851844 HHU_fl G1 June 7, 2023, 4:31 a.m. OK GNU C++20 (64) TESTS 136 31 0
208848307 diobrando97 G1 June 7, 2023, 3:31 a.m. OK GNU C++20 (64) TESTS 136 31 0
208832561 Ench_Lolz G1 June 6, 2023, 8:16 p.m. OK GNU C++20 (64) TESTS 136 31 0
208832220 Ench_Lolz G1 June 6, 2023, 8:10 p.m. OK GNU C++20 (64) TESTS 136 31 0
208842997 0x3F G1 June 7, 2023, 1:44 a.m. OK Go TESTS 136 93 307200
208826750 Dukkha G1 June 6, 2023, 6:47 p.m. OK Java 17 TESTS 136 405 1228800
208846946 Java_Programmer G1 June 7, 2023, 3:07 a.m. OK Java 8 TESTS 136 248 0
208818413 tukiTuki011 G1 June 6, 2023, 5:25 p.m. OK Java 8 TESTS 136 264 0
208831527 xuhao95 G1 June 6, 2023, 7:57 p.m. OK PyPy 3 TESTS 136 249 4710400
208814334 hacker70 G1 June 6, 2023, 5 p.m. OK PyPy 3 TESTS 136 265 5939200
208854580 parthtotalfun G1 June 7, 2023, 5:15 a.m. OK PyPy 3-64 TESTS 136 124 1740800
208842413 sunhokim G1 June 7, 2023, 1:30 a.m. OK PyPy 3-64 TESTS 136 140 3072000
208832049 beethoven97 G1 June 6, 2023, 8:07 p.m. OK PyPy 3-64 TESTS 136 155 2355200
208832088 beethoven97 G1 June 6, 2023, 8:08 p.m. OK PyPy 3-64 TESTS 136 156 2355200
208829807 beethoven97 G1 June 6, 2023, 7:30 p.m. OK PyPy 3-64 TESTS 136 171 2560000
208834000 kovir_aleksey_korroy G1 June 6, 2023, 8:47 p.m. OK PyPy 3-64 TESTS 136 187 5017600
208823085 ErreurFatale G1 June 6, 2023, 6:06 p.m. OK PyPy 3-64 TESTS 136 187 5529600
208852609 gardengnome G1 June 7, 2023, 4:43 a.m. OK PyPy 3-64 TESTS 136 202 5836800
208830401 pythonist_viking G1 June 6, 2023, 7:39 p.m. OK PyPy 3-64 TESTS 136 202 6963200
208837342 Ayush710 G1 June 6, 2023, 10:20 p.m. OK PyPy 3-64 TESTS 136 218 5836800

remove filters

Back to search problems