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 |
---|---|---|---|---|---|---|
1521 | Codeforces Round 720 (Div. 2) | FINISHED | False | 8100 | 116954711 | May 7, 2021, 2:35 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 4406 ) | C | Nastia and a Hidden Permutation | PROGRAMMING | constructive algorithms interactive |
B'This is an interactive problem! Nastia has a hidden permutation p of length n consisting of integers from 1 to n . You, for some reason, want to figure out the permutation. To do that, you can give her an integer t ( 1 <= t <= 2 ), two different indices i and j ( 1 <= i, j <= n , i neq j ), and an integer x ( 1 <= x <= n - 1 ). Depending on t , she will answer: You can ask Nastia at most lfloor frac {3 cdot n} { 2} rfloor + 30 times. It is guaranteed that she will not change her permutation depending on your queries. Can you guess the permutation? The input consists of several test cases. In the beginning, you receive the integer T ( 1 <= T <= 10 ,000 ) -- the number of test cases. At the beginning of each test case, you receive an integer n ( 3 <= n <= 10^4 ) -- the length of the permutation p . It 's guaranteed that the permutation is fixed beforehand and that the sum of n in one test doesn 't exceed 2 cdot 10^4 . To ask a question, print "? t i j x " ( t = 1 or t = 2 , 1 <= i, j <= n , i neq j , 1 <= x <= n - 1 ) Then, you should read the answer. If we answer with xe2 x88 x921 instead of a valid answer, that means you exceeded the number of queries or made an invalid query. Exit immediately after receiving xe2 x88 x921 and you will see the Wrong Answer verdict. Otherwise, you can get an arbitrary verdict because your solution will continue to read from a closed stream. To print the answer, print "! p_1 p_2 ldots p_{n} (without quotes). Note that answering doesn 't count as one of the lfloor frac {3 cdot n} {2} rfloor + 30 queries. After printing a query or printing the answer, do not forget to output end of line and flush the output. Otherwise, you will get Idleness limit exceeded. To do this, use: Hacks To hack the solution, use the following'... |
90477 |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
115629505 | rainboy | C | May 7, 2021, 6:48 p.m. | OK | GNU C11 | TESTS | 63 | 421 | 3788800 | ||
115652125 | RPChe_ dottle Lappland_Texas | C | May 8, 2021, 2:21 a.m. | OK | GNU C++11 | TESTS | 64 | 170 | 4403200 | ||
115657657 | cyh_toby | C | May 8, 2021, 3:59 a.m. | OK | GNU C++11 | TESTS | 64 | 187 | 3891200 | ||
115648325 | lanChe | C | May 8, 2021, 12:46 a.m. | OK | GNU C++11 | TESTS | 63 | 187 | 3993600 | ||
115649818 | 1443356159 Capitalist_Wang xuanyuan | C | May 8, 2021, 1:29 a.m. | OK | GNU C++11 | TESTS | 64 | 187 | 4096000 | ||
115632701 | biaohongAK | C | May 7, 2021, 7:30 p.m. | OK | GNU C++11 | TESTS | 63 | 202 | 3993600 | ||
115650237 | LegendaryYYQ final_trump Social_Zhao | C | May 8, 2021, 1:39 a.m. | OK | GNU C++11 | TESTS | 64 | 202 | 3993600 | ||
115618479 | iuiou | C | May 7, 2021, 4:49 p.m. | OK | GNU C++11 | TESTS | 61 | 202 | 4096000 | ||
115659618 | tyin | C | May 8, 2021, 4:32 a.m. | OK | GNU C++11 | TESTS | 64 | 202 | 4300800 | ||
115652024 | walk_alone | C | May 8, 2021, 2:19 a.m. | OK | GNU C++11 | TESTS | 64 | 217 | 3788800 | ||
115662580 | Momo_zzz | C | May 8, 2021, 5:13 a.m. | OK | GNU C++11 | TESTS | 64 | 217 | 4710400 | ||
115629144 | prayagshokeen1 | C | May 7, 2021, 6:44 p.m. | OK | GNU C++14 | TESTS | 63 | 280 | 3788800 | ||
115654047 | green_yyy | C | May 8, 2021, 2:57 a.m. | OK | GNU C++14 | TESTS | 64 | 280 | 3788800 | ||
115617355 | chase_the_next | C | May 7, 2021, 4:47 p.m. | OK | GNU C++14 | TESTS | 61 | 280 | 3788800 | ||
115641955 | Albert_Einstein | C | May 7, 2021, 9:42 p.m. | OK | GNU C++14 | TESTS | 63 | 280 | 3788800 | ||
115638770 | _bom_bom_ | C | May 7, 2021, 8:51 p.m. | OK | GNU C++14 | TESTS | 63 | 280 | 3891200 | ||
115626519 | chaitanyahardikar | C | May 7, 2021, 6:16 p.m. | OK | GNU C++14 | TESTS | 62 | 280 | 3891200 | ||
115638606 | Nasif_44th | C | May 7, 2021, 8:49 p.m. | OK | GNU C++14 | TESTS | 63 | 280 | 7782400 | ||
115653256 | zwu_2017010896 | C | May 8, 2021, 2:42 a.m. | OK | GNU C++14 | TESTS | 64 | 295 | 3788800 | ||
115660640 | meetjoshi | C | May 8, 2021, 4:46 a.m. | OK | GNU C++14 | TESTS | 64 | 295 | 3788800 | ||
115618440 | syrtin | C | May 7, 2021, 4:49 p.m. | OK | GNU C++14 | TESTS | 61 | 295 | 3788800 | ||
115659334 | hajibaghlol | C | May 8, 2021, 4:28 a.m. | OK | GNU C++17 | TESTS | 64 | 249 | 3891200 | ||
115642620 | aim100 | C | May 7, 2021, 9:55 p.m. | OK | GNU C++17 | TESTS | 63 | 249 | 4096000 | ||
115639922 | Ruki | C | May 7, 2021, 9:08 p.m. | OK | GNU C++17 | TESTS | 63 | 264 | 3788800 | ||
115624403 | TOKI_7s | C | May 7, 2021, 5:57 p.m. | OK | GNU C++17 | TESTS | 61 | 264 | 3788800 | ||
115618867 | orangesTO | C | May 7, 2021, 4:49 p.m. | OK | GNU C++17 | TESTS | 61 | 264 | 3788800 | ||
115655976 | jaspreetsingh08042 | C | May 8, 2021, 3:29 a.m. | OK | GNU C++17 | TESTS | 64 | 264 | 3788800 | ||
115623760 | parnbhatt23 | C | May 7, 2021, 5:53 p.m. | OK | GNU C++17 | TESTS | 61 | 264 | 3891200 | ||
115637811 | pj423 | C | May 7, 2021, 8:37 p.m. | OK | GNU C++17 | TESTS | 63 | 264 | 3891200 | ||
115623805 | crimsonred | C | May 7, 2021, 5:53 p.m. | OK | GNU C++17 | TESTS | 61 | 264 | 3891200 | ||
115625438 | kalyan72 | C | May 7, 2021, 6:06 p.m. | OK | GNU C++17 | TESTS | 61 | 265 | 3788800 | ||
115658721 | mysteri0us7 | C | May 8, 2021, 4:17 a.m. | OK | GNU C++17 (64) | TESTS | 64 | 218 | 4403200 | ||
115622307 | izlyforever | C | May 7, 2021, 5:42 p.m. | OK | GNU C++17 (64) | TESTS | 61 | 233 | 4300800 | ||
115625585 | 12tqian | C | May 7, 2021, 6:07 p.m. | OK | GNU C++17 (64) | TESTS | 61 | 234 | 4300800 | ||
115622361 | TimZheng | C | May 7, 2021, 5:42 p.m. | OK | GNU C++17 (64) | TESTS | 61 | 234 | 4300800 | ||
115626621 | WeakestTopology | C | May 7, 2021, 6:17 p.m. | OK | GNU C++17 (64) | TESTS | 62 | 248 | 4300800 | ||
115663163 | jainbot27 | C | May 8, 2021, 5:21 a.m. | OK | GNU C++17 (64) | TESTS | 64 | 249 | 4403200 | ||
115658877 | danielvitor23 | C | May 8, 2021, 4:20 a.m. | OK | GNU C++17 (64) | TESTS | 64 | 249 | 4403200 | ||
115628380 | ankurkayal | C | May 7, 2021, 6:35 p.m. | OK | GNU C++17 (64) | TESTS | 63 | 249 | 4403200 | ||
115619047 | 3ijk2ikj1kij | C | May 7, 2021, 4:49 p.m. | OK | GNU C++17 (64) | TESTS | 61 | 249 | 4403200 | ||
115639573 | kaiboy | C | May 7, 2021, 9:03 p.m. | OK | GNU C++17 (64) | TESTS | 63 | 264 | 4403200 | ||
115626975 | ypa | C | May 7, 2021, 6:20 p.m. | OK | Java 11 | TESTS | 62 | 1216 | 24473600 | ||
115626916 | ypa | C | May 7, 2021, 6:20 p.m. | OK | Java 11 | TESTS | 62 | 1263 | 24473600 | ||
115624329 | ypa | C | May 7, 2021, 5:57 p.m. | OK | Java 11 | TESTS | 61 | 1325 | 24473600 | ||
115661708 | ayush.18je0201 | C | May 8, 2021, 5:02 a.m. | OK | Java 11 | TESTS | 64 | 1388 | 25702400 | ||
115658672 | ranglelangle | C | May 8, 2021, 4:16 a.m. | OK | Java 11 | TESTS | 64 | 1435 | 25497600 | ||
115659944 | _merlin_ | C | May 8, 2021, 4:37 a.m. | OK | Java 11 | TESTS | 64 | 1544 | 24780800 | ||
115645878 | kareem3id | C | May 7, 2021, 11:13 p.m. | OK | Java 11 | TESTS | 63 | 1700 | 25395200 | ||
115661983 | Arjun-Ichiban | C | May 8, 2021, 5:05 a.m. | OK | Java 11 | TESTS | 64 | 1731 | 24064000 | ||
115658499 | pikachu_pika_pika | C | May 8, 2021, 4:13 a.m. | OK | Java 11 | TESTS | 64 | 2245 | 24678400 | ||
115630433 | This_is_the_one | C | May 7, 2021, 7 p.m. | OK | Java 8 | TESTS | 63 | 1185 | 20787200 | ||
115656977 | Abdallah_Ragab00 | C | May 8, 2021, 3:47 a.m. | OK | Java 8 | TESTS | 64 | 1200 | 20889600 | ||
115660014 | aggarwalanshul01 | C | May 8, 2021, 4:38 a.m. | OK | Java 8 | TESTS | 64 | 1357 | 20582400 | ||
115631653 | aryan_rn | C | May 7, 2021, 7:16 p.m. | OK | Java 8 | TESTS | 63 | 1403 | 22118400 | ||
115629154 | Agnimandur | C | May 7, 2021, 6:44 p.m. | OK | Java 8 | TESTS | 63 | 1450 | 20787200 | ||
115637586 | koper | C | May 7, 2021, 8:34 p.m. | OK | Kotlin | TESTS | 63 | 483 | 23142400 | ||
115639603 | DMN | C | May 7, 2021, 9:04 p.m. | OK | Mono C# | TESTS | 63 | 624 | 13926400 | ||
115659945 | jjune1416 | C | May 8, 2021, 4:37 a.m. | OK | MS C++ 2017 | TESTS | 64 | 451 | 3993600 | ||
115633647 | minigb | C | May 7, 2021, 7:45 p.m. | OK | MS C++ 2017 | TESTS | 63 | 514 | 3788800 | ||
115631329 | minigb | C | May 7, 2021, 7:12 p.m. | OK | MS C++ 2017 | TESTS | 63 | 514 | 3993600 | ||
115617451 | rishabnahar2025 | C | May 7, 2021, 4:47 p.m. | OK | PyPy 2 | TESTS | 61 | 1248 | 34201600 | ||
115628221 | reddevil100 | C | May 7, 2021, 6:33 p.m. | OK | PyPy 3 | TESTS | 63 | 951 | 29900800 | ||
115616158 | not_tehlka | C | May 7, 2021, 4:44 p.m. | OK | PyPy 3 | TESTS | 61 | 1029 | 29798400 | ||
115663266 | ShantanuTripathi | C | May 8, 2021, 5:22 a.m. | OK | PyPy 3 | TESTS | 64 | 1185 | 30105600 | ||
115625799 | at_f | C | May 7, 2021, 6:08 p.m. | OK | PyPy 3 | TESTS | 61 | 1216 | 29593600 | ||
115665413 | shiv_99 | C | May 8, 2021, 5:50 a.m. | OK | PyPy 3 | TESTS | 64 | 1216 | 29593600 | ||
115661523 | nicku123 | C | May 8, 2021, 4:59 a.m. | OK | PyPy 3 | TESTS | 64 | 1247 | 30208000 | ||
115627997 | zdu863 | C | May 7, 2021, 6:31 p.m. | OK | PyPy 3 | TESTS | 63 | 1279 | 30003200 | ||
115652551 | phantomxxx | C | May 8, 2021, 2:29 a.m. | OK | PyPy 3 | TESTS | 64 | 1294 | 30003200 | ||
115627796 | zdu863 | C | May 7, 2021, 6:29 p.m. | OK | PyPy 3 | TESTS | 63 | 1294 | 30105600 | ||
115626599 | zdu863 | C | May 7, 2021, 6:17 p.m. | OK | PyPy 3 | TESTS | 62 | 1294 | 30105600 | ||
115638459 | SSpikachu7890 | C | May 7, 2021, 8:46 p.m. | OK | Python 3 | TESTS | 63 | 826 | 7372800 | ||
115617497 | tusharjain0022 | C | May 7, 2021, 4:47 p.m. | OK | Python 3 | TESTS | 61 | 857 | 7372800 | ||
115627114 | r57shell | C | May 7, 2021, 6:21 p.m. | OK | Python 3 | TESTS | 62 | 1029 | 7782400 | ||
115626476 | r57shell | C | May 7, 2021, 6:15 p.m. | OK | Python 3 | TESTS | 62 | 1044 | 7782400 | ||
115657808 | sh1194 | C | May 8, 2021, 4:02 a.m. | OK | Python 3 | TESTS | 64 | 1138 | 7782400 | ||
115622973 | hxu10 | C | May 7, 2021, 5:46 p.m. | OK | Python 3 | TESTS | 61 | 1185 | 7987200 | ||
115623197 | hxu10 | C | May 7, 2021, 5:48 p.m. | OK | Python 3 | TESTS | 61 | 1357 | 7680000 | ||
115664433 | murch | C | May 8, 2021, 5:37 a.m. | OK | Rust | TESTS | 64 | 888 | 3993600 | ||
115660985 | murch | C | May 8, 2021, 4:51 a.m. | OK | Rust | TESTS | 64 | 982 | 3993600 |
Back to search problems