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 |
---|---|---|---|---|---|---|
1713 | Codeforces Round 812 (Div. 2) | FINISHED | False | 7200 | 77469863 | Aug. 6, 2022, 2:35 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 5784 ) | D | Tournament Countdown | PROGRAMMING | constructive algorithms fft greedy greedy interactive number theory probabilities | 1800 |
B'This is an interactive problem. There was a tournament consisting of 2^n contestants. The 1 -st contestant competed with the 2 -nd, the 3 -rd competed with the 4 -th, and so on. After that, the winner of the first match competed with the winner of second match, etc. The tournament ended when there was only one contestant left, who was declared the winner of the tournament. Such a tournament scheme is known as the single-elimination tournament. You don 't know the results, but you want to find the winner of the tournament. In one query, you select two integers a and b , which are the indices of two contestants. The jury will return 1 if a won more matches than b , 2 if b won more matches than a , or 0 if their number of wins was equal. Find the winner in no more than <= ft lceil frac{1}{3} cdot 2^{n + 1} right rceil queries. Here lceil x rceil denotes the value of x rounded up to the nearest integer. Note that the tournament is long over, meaning that the results are fixed and do not depend on your queries. The first line contains a single integer t ( 1 <= q t <= q 2^{14} ) -- the number of test cases. The only line of input contains a single integer n ( 1 <= q n <= q 17 ). It is guaranteed that the sum of 2^n over all test cases does not exceed 2^{17} . The interaction for each test case begins by reading the integer n . To make a query, output "? a b" ( 1 <= q a, b <= q 2^n ) without quotes. Afterwards, you should read one single integer -- the answer for your query. You can make at most <= ft lceil frac{1}{3} cdot 2^{n + 1} right rceil such queries in each test case. If you receive the integer -1 instead of an answer or a valid value of n , it means your program has made an invalid query, has exceed the limit of queries, or has given incorrect answer on the previous test case. Your program mu'... |
Codeforces Round #812 (Div. 2) Editorial |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
167300961 | chro4896 | D | Aug. 6, 2022, 4:28 p.m. | OK | GNU C11 | TESTS | 33 | 873 | 1331200 | 1800 | |
167338776 | TanJI | D | Aug. 7, 2022, 1:43 a.m. | OK | GNU C++14 | TESTS | 33 | 530 | 512000 | 1800 | |
167299280 | alien_lover | D | Aug. 6, 2022, 4:24 p.m. | OK | GNU C++14 | TESTS | 33 | 560 | 1228800 | 1800 | |
167341436 | WaheguruAnurag | D | Aug. 7, 2022, 2:34 a.m. | OK | GNU C++14 | TESTS | 33 | 608 | 512000 | 1800 | |
167340281 | vidushiiii | D | Aug. 7, 2022, 2:14 a.m. | OK | GNU C++14 | TESTS | 33 | 639 | 2252800 | 1800 | |
167340218 | zltzlt | D | Aug. 7, 2022, 2:13 a.m. | OK | GNU C++14 | TESTS | 33 | 670 | 1228800 | 1800 | |
167299242 | HakuroKawashiro | D | Aug. 6, 2022, 4:24 p.m. | OK | GNU C++14 | TESTS | 33 | 670 | 16076800 | 1800 | |
167343582 | Leasier | D | Aug. 7, 2022, 3:12 a.m. | OK | GNU C++14 | TESTS | 33 | 685 | 614400 | 1800 | |
167303273 | expecting | D | Aug. 6, 2022, 4:32 p.m. | OK | GNU C++14 | TESTS | 33 | 686 | 0 | 1800 | |
167327697 | Wael_Zaiback | D | Aug. 6, 2022, 9:07 p.m. | OK | GNU C++14 | TESTS | 33 | 686 | 1126400 | 1800 | |
167343792 | include_BM | D | Aug. 7, 2022, 3:15 a.m. | OK | GNU C++14 | TESTS | 33 | 686 | 1126400 | 1800 | |
167328747 | l.lawliet | D | Aug. 6, 2022, 9:27 p.m. | OK | GNU C++17 | TESTS | 33 | 529 | 2252800 | 1800 | |
167302145 | Alen777 | D | Aug. 6, 2022, 4:30 p.m. | OK | GNU C++17 | TESTS | 33 | 561 | 2252800 | 1800 | |
167313338 | richardl02 | D | Aug. 6, 2022, 6:25 p.m. | OK | GNU C++17 | TESTS | 33 | 576 | 819200 | 1800 | |
167303946 | MO_Salah99 | D | Aug. 6, 2022, 4:33 p.m. | OK | GNU C++17 | TESTS | 33 | 577 | 1228800 | 1800 | |
167313345 | tzar | D | Aug. 6, 2022, 6:25 p.m. | OK | GNU C++17 | TESTS | 33 | 577 | 19558400 | 1800 | |
167328995 | MAKLN | D | Aug. 6, 2022, 9:31 p.m. | OK | GNU C++17 | TESTS | 33 | 592 | 512000 | 1800 | |
167313022 | Soumya_Patra | D | Aug. 6, 2022, 6:23 p.m. | OK | GNU C++17 | TESTS | 33 | 592 | 1228800 | 1800 | |
167348202 | know | D | Aug. 7, 2022, 4:32 a.m. | OK | GNU C++17 | TESTS | 33 | 592 | 2048000 | 1800 | |
167347798 | codermaniac | D | Aug. 7, 2022, 4:25 a.m. | OK | GNU C++17 | TESTS | 33 | 592 | 2764800 | 1800 | |
167299946 | code_fury101 | D | Aug. 6, 2022, 4:26 p.m. | OK | GNU C++17 | TESTS | 33 | 592 | 21913600 | 1800 | |
167341283 | trantri10503 | D | Aug. 7, 2022, 2:31 a.m. | OK | GNU C++17 (64) | TESTS | 33 | 483 | 1126400 | 1800 | |
167341246 | trantri10503 | D | Aug. 7, 2022, 2:30 a.m. | OK | GNU C++17 (64) | TESTS | 33 | 530 | 614400 | 1800 | |
167326251 | gigabuffoon | D | Aug. 6, 2022, 8:44 p.m. | OK | GNU C++17 (64) | TESTS | 33 | 545 | 1638400 | 1800 | |
167312955 | Edu175 | D | Aug. 6, 2022, 6:23 p.m. | OK | GNU C++17 (64) | TESTS | 33 | 592 | 2150400 | 1800 | |
167327197 | KevinSimp | D | Aug. 6, 2022, 8:59 p.m. | OK | GNU C++17 (64) | TESTS | 33 | 592 | 2150400 | 1800 | |
167339065 | CSUST_GXL | D | Aug. 7, 2022, 1:50 a.m. | OK | GNU C++17 (64) | TESTS | 33 | 624 | 2150400 | 1800 | |
167343596 | Colala | D | Aug. 7, 2022, 3:12 a.m. | OK | GNU C++17 (64) | TESTS | 33 | 639 | 512000 | 1800 | |
167325862 | gigabuffoon | D | Aug. 6, 2022, 8:38 p.m. | OK | GNU C++17 (64) | TESTS | 33 | 639 | 1638400 | 1800 | |
167338010 | CedeaT0 | D | Aug. 7, 2022, 1:25 a.m. | OK | GNU C++17 (64) | TESTS | 33 | 654 | 3686400 | 1800 | |
167302959 | vljxjg | D | Aug. 6, 2022, 4:32 p.m. | OK | GNU C++17 (64) | TESTS | 33 | 654 | 3993600 | 1800 | |
167320130 | harpreet1237 | D | Aug. 6, 2022, 7:26 p.m. | OK | GNU C++20 (64) | TESTS | 33 | 483 | 4198400 | 1800 | |
167327747 | ItsNikolor | D | Aug. 6, 2022, 9:08 p.m. | OK | GNU C++20 (64) | TESTS | 33 | 514 | 921600 | 1800 | |
167318880 | codeyourlife | D | Aug. 6, 2022, 7:13 p.m. | OK | GNU C++20 (64) | TESTS | 33 | 514 | 4300800 | 1800 | |
167314861 | EmadSamy | D | Aug. 6, 2022, 6:35 p.m. | OK | GNU C++20 (64) | TESTS | 33 | 530 | 2150400 | 1800 | |
167315287 | codeomaniac2022 | D | Aug. 6, 2022, 6:39 p.m. | OK | GNU C++20 (64) | TESTS | 33 | 545 | 1126400 | 1800 | |
167321369 | Elias_Obeid | D | Aug. 6, 2022, 7:40 p.m. | OK | GNU C++20 (64) | TESTS | 33 | 546 | 1126400 | 1800 | |
167348804 | coderdhanraj | D | Aug. 7, 2022, 4:41 a.m. | OK | GNU C++20 (64) | TESTS | 33 | 561 | 2150400 | 1800 | |
167316774 | JaroPaska | D | Aug. 6, 2022, 6:52 p.m. | OK | GNU C++20 (64) | TESTS | 33 | 576 | 1126400 | 1800 | |
167354499 | Tommy_Shan | D | Aug. 7, 2022, 5:55 a.m. | OK | GNU C++20 (64) | TESTS | 33 | 576 | 2150400 | 1800 | |
167314039 | abhinavawasthi | D | Aug. 6, 2022, 6:29 p.m. | OK | GNU C++20 (64) | TESTS | 33 | 592 | 2150400 | 1800 | |
167314758 | protogrammer | D | Aug. 6, 2022, 6:34 p.m. | OK | Go | TESTS | 33 | 1138 | 1331200 | 1800 | |
167319282 | freehandle | D | Aug. 6, 2022, 7:17 p.m. | OK | Java 11 | TESTS | 33 | 1513 | 0 | 1800 | |
167326063 | profchi | D | Aug. 6, 2022, 8:41 p.m. | OK | Java 11 | TESTS | 33 | 1762 | 0 | 1800 | |
167329727 | mcrash12 | D | Aug. 6, 2022, 9:46 p.m. | OK | Java 11 | TESTS | 33 | 1902 | 0 | 1800 | |
167318471 | dzhi | D | Aug. 6, 2022, 7:09 p.m. | OK | Java 11 | TESTS | 33 | 1934 | 0 | 1800 | |
167338941 | Jeg | D | Aug. 7, 2022, 1:47 a.m. | OK | Java 11 | TESTS | 33 | 1965 | 819200 | 1800 | |
167339047 | Jeg | D | Aug. 7, 2022, 1:49 a.m. | OK | Java 11 | TESTS | 33 | 1980 | 819200 | 1800 | |
167316871 | dunkingdonuts | D | Aug. 6, 2022, 6:53 p.m. | OK | Java 11 | TESTS | 33 | 1996 | 0 | 1800 | |
167318788 | Nicolas125841 | D | Aug. 6, 2022, 7:12 p.m. | OK | Java 11 | TESTS | 33 | 1996 | 204800 | 1800 | |
167339082 | Jeg | D | Aug. 7, 2022, 1:50 a.m. | OK | Java 11 | TESTS | 33 | 1996 | 819200 | 1800 | |
167324665 | Abhi_Valani | D | Aug. 6, 2022, 8:21 p.m. | OK | Java 11 | TESTS | 33 | 1996 | 1024000 | 1800 | |
167321948 | freehandle | D | Aug. 6, 2022, 7:46 p.m. | OK | Java 17 | TESTS | 33 | 1247 | 921600 | 1800 | |
167321397 | freehandle | D | Aug. 6, 2022, 7:40 p.m. | OK | Java 17 | TESTS | 33 | 1294 | 1024000 | 1800 | |
167319767 | freehandle | D | Aug. 6, 2022, 7:22 p.m. | OK | Java 17 | TESTS | 33 | 1388 | 716800 | 1800 | |
167319264 | freehandle | D | Aug. 6, 2022, 7:17 p.m. | OK | Java 17 | TESTS | 33 | 1606 | 921600 | 1800 | |
167322025 | freehandle | D | Aug. 6, 2022, 7:47 p.m. | OK | Java 17 | TESTS | 33 | 1762 | 921600 | 1800 | |
167318118 | freehandle | D | Aug. 6, 2022, 7:05 p.m. | OK | Java 17 | TESTS | 33 | 1934 | 921600 | 1800 | |
167319224 | freehandle | D | Aug. 6, 2022, 7:17 p.m. | OK | Java 8 | TESTS | 33 | 1544 | 0 | 1800 | |
167312288 | mwen | D | Aug. 6, 2022, 6:20 p.m. | OK | Java 8 | TESTS | 33 | 1668 | 0 | 1800 | |
167342095 | Zahid_Hasan_Sahin | D | Aug. 7, 2022, 2:47 a.m. | OK | Java 8 | TESTS | 33 | 1762 | 0 | 1800 | |
167318167 | freehandle | D | Aug. 6, 2022, 7:06 p.m. | OK | Java 8 | TESTS | 33 | 1762 | 0 | 1800 | |
167317064 | dunkingdonuts | D | Aug. 6, 2022, 6:55 p.m. | OK | Java 8 | TESTS | 33 | 1887 | 0 | 1800 | |
167321341 | NatInTheHat | D | Aug. 6, 2022, 7:39 p.m. | OK | Java 8 | TESTS | 33 | 1996 | 0 | 1800 | |
167302203 | junehop | D | Aug. 6, 2022, 4:30 p.m. | OK | JavaScript | TESTS | 33 | 1060 | 8089600 | 1800 | |
167318698 | batkhuyag | D | Aug. 6, 2022, 7:11 p.m. | OK | Kotlin 1.6 | TESTS | 33 | 1372 | 0 | 1800 | |
167318759 | ItsNikolor | D | Aug. 6, 2022, 7:11 p.m. | OK | MS C++ 2017 | TESTS | 33 | 795 | 1433600 | 1800 | |
167325844 | ItsNikolor | D | Aug. 6, 2022, 8:38 p.m. | OK | MS C++ 2017 | TESTS | 33 | 1123 | 1536000 | 1800 | |
167320403 | justdhs | D | Aug. 6, 2022, 7:29 p.m. | OK | MS C++ 2017 | TESTS | 33 | 1185 | 1945600 | 1800 | |
167348223 | misorin | D | Aug. 7, 2022, 4:32 a.m. | OK | PyPy 2 | TESTS | 33 | 794 | 6963200 | 1800 | |
167347368 | misorin | D | Aug. 7, 2022, 4:17 a.m. | OK | PyPy 2 | TESTS | 33 | 795 | 5017600 | 1800 | |
167319565 | misorin | D | Aug. 6, 2022, 7:20 p.m. | OK | PyPy 2 | TESTS | 33 | 1013 | 7168000 | 1800 | |
167318315 | misorin | D | Aug. 6, 2022, 7:07 p.m. | OK | PyPy 2 | TESTS | 33 | 1138 | 5529600 | 1800 | |
167320270 | juLeena | D | Aug. 6, 2022, 7:28 p.m. | OK | PyPy 2 | TESTS | 33 | 1574 | 5836800 | 1800 | |
167314863 | Ayushman_123 | D | Aug. 6, 2022, 6:35 p.m. | OK | PyPy 2 | TESTS | 33 | 1575 | 5529600 | 1800 | |
167320115 | juLeena | D | Aug. 6, 2022, 7:26 p.m. | OK | PyPy 2 | TESTS | 33 | 1622 | 5836800 | 1800 | |
167323318 | juLeena | D | Aug. 6, 2022, 8:04 p.m. | OK | PyPy 2 | TESTS | 33 | 1653 | 8089600 | 1800 | |
167314374 | Ayushman_123 | D | Aug. 6, 2022, 6:32 p.m. | OK | PyPy 2 | TESTS | 33 | 1731 | 6348800 | 1800 | |
167314017 | SophieHatter | D | Aug. 6, 2022, 6:29 p.m. | OK | PyPy 2 | TESTS | 33 | 1902 | 8192000 | 1800 | |
167315701 | misorin | D | Aug. 6, 2022, 6:43 p.m. | OK | PyPy 3 | TESTS | 33 | 1216 | 6144000 | 1800 | |
167321912 | hxu10 | D | Aug. 6, 2022, 7:46 p.m. | OK | PyPy 3 | TESTS | 33 | 1294 | 6144000 | 1800 | |
167321223 | HETRAKESHFADIA | D | Aug. 6, 2022, 7:38 p.m. | OK | PyPy 3 | TESTS | 33 | 1590 | 9830400 | 1800 | |
167320664 | HETRAKESHFADIA | D | Aug. 6, 2022, 7:32 p.m. | OK | PyPy 3 | TESTS | 33 | 1652 | 9318400 | 1800 | |
167314003 | misorin | D | Aug. 6, 2022, 6:29 p.m. | OK | PyPy 3 | TESTS | 33 | 1793 | 6656000 | 1800 | |
167348149 | eepsilon | D | Aug. 7, 2022, 4:31 a.m. | OK | PyPy 3 | TESTS | 33 | 1950 | 10035200 | 1800 | |
167333608 | toam | D | Aug. 6, 2022, 11:26 p.m. | OK | PyPy 3 | TESTS | 33 | 1964 | 10240000 | 1800 | |
167353237 | kittarshire | D | Aug. 7, 2022, 5:40 a.m. | OK | PyPy 3 | TESTS | 33 | 1996 | 9728000 | 1800 | |
167348280 | misorin | D | Aug. 7, 2022, 4:33 a.m. | OK | PyPy 3-64 | TESTS | 33 | 780 | 12288000 | 1800 | |
167347304 | misorin | D | Aug. 7, 2022, 4:16 a.m. | OK | PyPy 3-64 | TESTS | 33 | 826 | 10137600 | 1800 | |
167315795 | misorin | D | Aug. 6, 2022, 6:43 p.m. | OK | PyPy 3-64 | TESTS | 33 | 1060 | 9625600 | 1800 | |
167319694 | misorin | D | Aug. 6, 2022, 7:21 p.m. | OK | PyPy 3-64 | TESTS | 33 | 1091 | 10854400 | 1800 | |
167328079 | a_vantik_a | D | Aug. 6, 2022, 9:14 p.m. | OK | PyPy 3-64 | TESTS | 33 | 1185 | 14438400 | 1800 | |
167326080 | BinaryGambit05 | D | Aug. 6, 2022, 8:41 p.m. | OK | PyPy 3-64 | TESTS | 33 | 1216 | 12390400 | 1800 | |
167333802 | toam | D | Aug. 6, 2022, 11:31 p.m. | OK | PyPy 3-64 | TESTS | 33 | 1232 | 9830400 | 1800 | |
167326396 | BinaryGambit05 | D | Aug. 6, 2022, 8:46 p.m. | OK | PyPy 3-64 | TESTS | 33 | 1232 | 14643200 | 1800 | |
167349520 | dalgu | D | Aug. 7, 2022, 4:52 a.m. | OK | PyPy 3-64 | TESTS | 33 | 1263 | 9932800 | 1800 | |
167349726 | dalgu | D | Aug. 7, 2022, 4:55 a.m. | OK | PyPy 3-64 | TESTS | 33 | 1263 | 10035200 | 1800 | |
167347462 | misorin | D | Aug. 7, 2022, 4:19 a.m. | OK | Python 2 | TESTS | 33 | 842 | 3686400 | 1800 | |
167323261 | bobxiong88 | D | Aug. 6, 2022, 8:03 p.m. | OK | Python 2 | TESTS | 33 | 1309 | 4096000 | 1800 | |
167320447 | juLeena | D | Aug. 6, 2022, 7:29 p.m. | OK | Python 2 | TESTS | 33 | 1419 | 3788800 | 1800 | |
167323404 | juLeena | D | Aug. 6, 2022, 8:05 p.m. | OK | Python 2 | TESTS | 33 | 1513 | 3584000 | 1800 | |
167320963 | HETRAKESHFADIA | D | Aug. 6, 2022, 7:35 p.m. | OK | Python 3 | TESTS | 33 | 1262 | 3891200 | 1800 | |
167320212 | HETRAKESHFADIA | D | Aug. 6, 2022, 7:27 p.m. | OK | Python 3 | TESTS | 33 | 1840 | 3788800 | 1800 | |
167345556 | MistaAsh | D | Aug. 7, 2022, 3:44 a.m. | OK | Python 3 | TESTS | 33 | 1856 | 6041600 | 1800 | |
167319952 | sushmanth.dampur8780 | D | Aug. 6, 2022, 7:24 p.m. | OK | Python 3 | TESTS | 33 | 1871 | 4403200 | 1800 | |
167316052 | shehebe | D | Aug. 6, 2022, 6:46 p.m. | OK | Python 3 | TESTS | 33 | 1903 | 4505600 | 1800 | |
167299050 | SPD_9X2 | D | Aug. 6, 2022, 4:24 p.m. | OK | Python 3 | TESTS | 33 | 1980 | 3379200 | 1800 | |
167314672 | jano31415 | D | Aug. 6, 2022, 6:34 p.m. | OK | Python 3 | TESTS | 33 | 1996 | 2560000 | 1800 | |
167331273 | LittleFall | D | Aug. 6, 2022, 10:21 p.m. | OK | Rust 2021 | TESTS | 33 | 1123 | 1024000 | 1800 | |
167331240 | LittleFall | D | Aug. 6, 2022, 10:20 p.m. | OK | Rust 2021 | TESTS | 33 | 1123 | 1024000 | 1800 | |
167317973 | tngyl | D | Aug. 6, 2022, 7:04 p.m. | OK | Rust 2021 | TESTS | 33 | 1154 | 3174400 | 1800 | |
167323190 | robostac | D | Aug. 6, 2022, 8:02 p.m. | OK | Rust 2021 | TESTS | 33 | 1279 | 1024000 | 1800 | |
167329616 | LittleFall | D | Aug. 6, 2022, 9:43 p.m. | OK | Rust 2021 | TESTS | 33 | 1309 | 819200 | 1800 | |
167314326 | kena0ki | D | Aug. 6, 2022, 6:31 p.m. | OK | Rust 2021 | TESTS | 33 | 1326 | 1024000 | 1800 | |
167324115 | robostac | D | Aug. 6, 2022, 8:14 p.m. | OK | Rust 2021 | TESTS | 33 | 1341 | 819200 | 1800 | |
167319964 | robostac | D | Aug. 6, 2022, 7:24 p.m. | OK | Rust 2021 | TESTS | 33 | 1341 | 1433600 | 1800 | |
167330076 | LittleFall | D | Aug. 6, 2022, 9:53 p.m. | OK | Rust 2021 | TESTS | 33 | 1357 | 819200 | 1800 | |
167323909 | robostac | D | Aug. 6, 2022, 8:11 p.m. | OK | Rust 2021 | TESTS | 33 | 1372 | 819200 | 1800 |
Back to search problems