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 |
|---|---|---|---|---|---|---|
| 2066 | Codeforces Round 1004 (Div. 1) | FINISHED | False | 7200 | 37121123 | Feb. 11, 2025, 2:35 p.m. |
Solved |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
|---|---|---|---|---|---|---|
| ( 7121 ) | A | Object Identification | PROGRAMMING | graphs implementation interactive |
This is an interactive problem. You are given an array (x_1, \ldots, x_n) of integers from (1) to (n). The jury also has a fixed but hidden array (y_1, \ldots, y_n) of integers from (1) to (n). The elements of array (y) are unknown to you. Additionally, it is known that for all (i), (x_i \neq y_i), and all pairs ((x_i, y_i)) are distinct. The jury has secretly thought of one of two objects, and you need to determine which one it is: Object A : A directed graph with (n) vertices numbered from (1) to (n), and with (n) edges of the form (x_i \to y_i). Object B : (n) points on a coordinate plane. The (i)-th point has coordinates ((x_i, y_i)). To guess which object the jury has thought of, you can make queries. In one query, you must specify two numbers (i, j) ((1 \leq i, j \leq n, i \neq j)). In response, you receive one number: If the jury has thought of Object A , you receive the length of the shortest path (in edges) from vertex (i) to vertex (j) in the graph, or (0) if there is no path. If the jury has thought of Object B , you receive the Manhattan distance between points (i) and (j), that is (|x_i -x_j| + |y_i - y_j|). You have (2) queries to determine which of the objects the jury has thought of. Each test contains multiple test cases. The first line contains the number of test cases (t) ((1 \le t \le 1000)). The description of the test cases follows. The interaction begins with reading (n) ((3 \leq n \leq 2 \cdot 10^5)) — the length of the arrays (x) and (y) at the start of each test case. Next, read (n) integers: (x_1, x_2, \ldots, x_n) ((1 \leq x_i \leq n)) — the elements of array (x). It is guaranteed that the sum of (n) across all test cases does not exceed (2 \cdot 10^5). The array (y_1, y_2, \ldots, y_n) is fixed for each test case. In other words, the interactor is not adaptive. It is gua |
| 139415 |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
|---|---|---|---|---|---|---|---|---|---|---|---|
| 305705548 | og.kostya | A | Feb. 11, 2025, 5:31 p.m. | OK | C# 10 | TESTS | 27 | 155 | 16998400 | ||
| 305646633 | mban259 | A | Feb. 11, 2025, 3:11 p.m. | OK | C# 10 | TESTS | 27 | 171 | 14540800 | ||
| 305640152 | Noobish_Monk | A | Feb. 11, 2025, 3:03 p.m. | OK | C++17 (GCC 7-32) | TESTS | 27 | 108 | 0 | ||
| 305645894 | rulerofcakes | A | Feb. 11, 2025, 3:10 p.m. | OK | C++17 (GCC 7-32) | TESTS | 27 | 108 | 102400 | ||
| 305685213 | OIerGegu1019 | A | Feb. 11, 2025, 4:12 p.m. | OK | C++17 (GCC 7-32) | TESTS | 27 | 108 | 1024000 | ||
| 305630100 | Andreasyan | A | Feb. 11, 2025, 2:53 p.m. | OK | C++17 (GCC 7-32) | TESTS | 27 | 108 | 1638400 | ||
| 305754086 | LXH-cat | A | Feb. 12, 2025, 4:08 a.m. | OK | C++17 (GCC 7-32) | TESTS | 27 | 108 | 1638400 | ||
| 305630549 | arash. | A | Feb. 11, 2025, 2:54 p.m. | OK | C++17 (GCC 7-32) | TESTS | 27 | 108 | 2560000 | ||
| 305634321 | ScottChou | A | Feb. 11, 2025, 2:58 p.m. | OK | C++17 (GCC 7-32) | TESTS | 27 | 108 | 3276800 | ||
| 305640354 | Yugi.Hacker | A | Feb. 11, 2025, 3:04 p.m. | OK | C++17 (GCC 7-32) | TESTS | 27 | 109 | 0 | ||
| 305756622 | B_3 | A | Feb. 12, 2025, 4:40 a.m. | OK | C++17 (GCC 7-32) | TESTS | 27 | 109 | 0 | ||
| 305644923 | lacito | A | Feb. 11, 2025, 3:09 p.m. | OK | C++17 (GCC 7-32) | TESTS | 27 | 109 | 0 | ||
| 305746470 | dog_of_Nesraychan | A | Feb. 12, 2025, 2:13 a.m. | OK | C++20 (GCC 13-64) | TESTS | 27 | 77 | 1024000 | ||
| 305641014 | petr3126 | A | Feb. 11, 2025, 3:04 p.m. | OK | C++20 (GCC 13-64) | TESTS | 27 | 93 | 102400 | ||
| 305712610 | xiwap8 | A | Feb. 11, 2025, 6:13 p.m. | OK | C++20 (GCC 13-64) | TESTS | 27 | 93 | 102400 | ||
| 305618364 | dorijanlendvaj | A | Feb. 11, 2025, 2:42 p.m. | OK | C++20 (GCC 13-64) | TESTS | 27 | 93 | 1228800 | ||
| 305645263 | Mapakaka | A | Feb. 11, 2025, 3:09 p.m. | OK | C++20 (GCC 13-64) | TESTS | 27 | 93 | 1638400 | ||
| 305753175 | ngmhhay | A | Feb. 12, 2025, 3:57 a.m. | OK | C++20 (GCC 13-64) | TESTS | 27 | 93 | 1638400 | ||
| 305623498 | cxm1024 | A | Feb. 11, 2025, 2:47 p.m. | OK | C++20 (GCC 13-64) | TESTS | 27 | 93 | 1638400 | ||
| 305651901 | maxplus | A | Feb. 11, 2025, 3:17 p.m. | OK | C++20 (GCC 13-64) | TESTS | 27 | 108 | 0 | ||
| 305761997 | LoveDaiDaiShu | A | Feb. 12, 2025, 5:47 a.m. | OK | C++20 (GCC 13-64) | TESTS | 27 | 108 | 0 | ||
| 305658423 | ivatopuria | A | Feb. 11, 2025, 3:27 p.m. | OK | C++20 (GCC 13-64) | TESTS | 27 | 108 | 0 | ||
| 305750675 | rgrgtgrf | A | Feb. 12, 2025, 3:20 a.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 27 | 93 | 0 | ||
| 305634028 | DeMen100ns | A | Feb. 11, 2025, 2:57 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 27 | 93 | 102400 | ||
| 305656106 | hardenisthegoat | A | Feb. 11, 2025, 3:23 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 27 | 93 | 102400 | ||
| 305655617 | t9unkubj | A | Feb. 11, 2025, 3:23 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 27 | 93 | 102400 | ||
| 305620045 | GroupMatrix | A | Feb. 11, 2025, 2:44 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 27 | 93 | 1638400 | ||
| 305751838 | wjh2011 | A | Feb. 12, 2025, 3:39 a.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 27 | 93 | 1638400 | ||
| 305625325 | TRDOG | A | Feb. 11, 2025, 2:48 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 27 | 93 | 9113600 | ||
| 305754752 | FangYifan | A | Feb. 12, 2025, 4:16 a.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 27 | 108 | 0 | ||
| 305640422 | EthanKim8683 | A | Feb. 11, 2025, 3:04 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 27 | 108 | 0 | ||
| 305760847 | yzy123443 | A | Feb. 12, 2025, 5:34 a.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 27 | 108 | 102400 | ||
| 305650475 | hos.lyric | A | Feb. 11, 2025, 3:15 p.m. | OK | D | TESTS | 27 | 155 | 10444800 | ||
| 305629489 | Gassa | A | Feb. 11, 2025, 2:53 p.m. | OK | D | TESTS | 27 | 155 | 10649600 | ||
| 305742931 | rainboy | A | Feb. 12, 2025, 1:06 a.m. | OK | GNU C11 | TESTS | 27 | 140 | 9216000 | ||
| 305649321 | d.o. | A | Feb. 11, 2025, 3:14 p.m. | OK | Go | TESTS | 27 | 218 | 18329600 | ||
| 305642590 | Quasicoherent | A | Feb. 11, 2025, 3:06 p.m. | OK | Java 21 | TESTS | 27 | 405 | 1536000 | ||
| 305691097 | Electromaster | A | Feb. 11, 2025, 4:23 p.m. | OK | Kotlin 1.9 | TESTS | 27 | 530 | 31129600 | ||
| 305636635 | SPD_9X2 | A | Feb. 11, 2025, 3 p.m. | OK | PyPy 3 | TESTS | 27 | 530 | 24883200 | ||
| 305642424 | yupooh | A | Feb. 11, 2025, 3:06 p.m. | OK | PyPy 3-64 | TESTS | 27 | 202 | 20684800 | ||
| 305639243 | smilences | A | Feb. 11, 2025, 3:03 p.m. | OK | PyPy 3-64 | TESTS | 27 | 202 | 21606400 | ||
| 305760631 | teekaytai | A | Feb. 12, 2025, 5:32 a.m. | OK | PyPy 3-64 | TESTS | 27 | 217 | 28569600 | ||
| 305630740 | chinerist | A | Feb. 11, 2025, 2:54 p.m. | OK | PyPy 3-64 | TESTS | 27 | 218 | 24473600 | ||
| 305741701 | conqueror_of_tourist | A | Feb. 12, 2025, 12:39 a.m. | OK | PyPy 3-64 | TESTS | 27 | 233 | 20992000 | ||
| 305654730 | hxu10 | A | Feb. 11, 2025, 3:21 p.m. | OK | PyPy 3-64 | TESTS | 27 | 233 | 21094400 | ||
| 305624170 | toam | A | Feb. 11, 2025, 2:47 p.m. | OK | PyPy 3-64 | TESTS | 27 | 233 | 21401600 | ||
| 305748172 | suo_4r | A | Feb. 12, 2025, 2:42 a.m. | OK | PyPy 3-64 | TESTS | 27 | 249 | 21606400 | ||
| 305653959 | eepsilon | A | Feb. 11, 2025, 3:20 p.m. | OK | PyPy 3-64 | TESTS | 27 | 249 | 24166400 | ||
| 305645864 | TopazDragon89 | A | Feb. 11, 2025, 3:10 p.m. | OK | PyPy 3-64 | TESTS | 27 | 249 | 27852800 | ||
| 305662744 | Jimanbanashi | A | Feb. 11, 2025, 3:33 p.m. | OK | Python 2 | TESTS | 27 | 515 | 15257600 | ||
| 305652766 | Egor | A | Feb. 11, 2025, 3:18 p.m. | OK | Rust 2021 | TESTS | 27 | 109 | 204800 | ||
| 305631744 | cologne1723 | A | Feb. 11, 2025, 2:55 p.m. | OK | Rust 2021 | TESTS | 27 | 109 | 1536000 | ||
| 305633878 | sansen | A | Feb. 11, 2025, 2:57 p.m. | OK | Rust 2021 | TESTS | 27 | 124 | 1536000 |
Back to search problems