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 |
|---|---|---|---|---|---|---|
| 2138 | Codeforces Round 1048 (Div. 1) | FINISHED | False | 10800 | 19063523 | Sept. 8, 2025, 2:35 p.m. |
Solved |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
|---|---|---|---|---|---|---|
| ( 633 ) | D | Antiamuny and Slider Movement | PROGRAMMING | binary search brute force combinatorics implementation math |
Antiamuny is managing (n) sliders on a one-dimensional track of length (m). Each slider occupies exactly one unit of space and starts at a distinct position. The sliders are numbered from (1) to (n) and are arranged from left to right, so that the (i)-th slider is initially at position (a_i). Antiamuny is given (q) operations. Each operation is described by two integers (i) and (x) ((1\le i\le n), (i \leq x \leq m - n + i)). The operation moves the (i)-th slider to position (x). However, if this move causes a collision with another slider (i.e., if there is any other slider between the (i)-th slider's current position and the destination (x)), that obstructing slider is pushed in the same direction by one unit until it no longer causes a collision with the (i)-th slider. This can trigger a chain reaction, where one slider pushes another, and so on, until all sliders occupy distinct positions again. Importantly, note that the operations do not change the relative ordering of the sliders: the (i)-th slider from the left will remain as the (i)-th slider from the left. Furthermore, the constraints on (x) ensure that all sliders always remain on the track, with positions between (1) and (m). For example, suppose the initial slider positions are (1, 3, 5, 7, 9). If the fifth slider (at position (9)) is moved to position (6), it will push the fourth slider from (7) to (5), which in turn pushes the third slider from (5) to (4). The resulting positions become (1, 3, \textbf{4}, \textbf{5}, \textbf{6}). Unfortunately, Antiamuny has forgotten the order in which the (q) operations were applied. To recover the results, he decides to independently simulate each of the (q!) possible permutations of the operations. For each permutation (p) of length (q)(^{\text{∗}}), define (f_i(p)) as the final position of the (i)-th slider a |
| Codeforces Round 1048 (Div. 1, Div. 2) Editorial |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
|---|---|---|---|---|---|---|---|---|---|---|---|
| 337658456 | fengqiyuka | D | Sept. 8, 2025, 5:28 p.m. | OK | C++17 (GCC 7-32) | TESTS | 29 | 733 | 102400 | ||
| 337705273 | chenyuyang0225 | D | Sept. 9, 2025, 5:58 a.m. | OK | C++17 (GCC 7-32) | TESTS | 29 | 811 | 307200 | ||
| 337659708 | Macesuted-Moe | D | Sept. 8, 2025, 5:32 p.m. | OK | C++17 (GCC 7-32) | TESTS | 29 | 968 | 512000 | ||
| 337646572 | Numbering | D | Sept. 8, 2025, 4:52 p.m. | OK | C++17 (GCC 7-32) | TESTS | 29 | 1233 | 307200 | ||
| 337703008 | ComPhyPark | D | Sept. 9, 2025, 5:29 a.m. | OK | C++17 (GCC 7-32) | TESTS | 29 | 1452 | 409600 | ||
| 337649214 | linyue | D | Sept. 8, 2025, 4:59 p.m. | OK | C++17 (GCC 7-32) | TESTS | 29 | 1999 | 10137600 | ||
| 337654128 | suyiheng | D | Sept. 8, 2025, 5:14 p.m. | OK | C++17 (GCC 7-32) | TESTS | 29 | 2062 | 204800 | ||
| 337653156 | weebyes | D | Sept. 8, 2025, 5:11 p.m. | OK | C++17 (GCC 7-32) | TESTS | 29 | 2311 | 102400 | ||
| 337658887 | Isoeasy | D | Sept. 8, 2025, 5:29 p.m. | OK | C++17 (GCC 7-32) | TESTS | 29 | 2889 | 100761600 | ||
| 337653759 | Az3ar | D | Sept. 8, 2025, 5:13 p.m. | OK | C++17 (GCC 7-32) | TESTS | 29 | 3108 | 100659200 | ||
| 337632992 | bjcb | D | Sept. 8, 2025, 4:19 p.m. | OK | C++20 (GCC 13-64) | TESTS | 29 | 218 | 0 | ||
| 337628135 | EnuTieTie | D | Sept. 8, 2025, 4:08 p.m. | OK | C++20 (GCC 13-64) | TESTS | 29 | 280 | 102400 | ||
| 337635370 | _Diu_ | D | Sept. 8, 2025, 4:24 p.m. | OK | C++20 (GCC 13-64) | TESTS | 29 | 328 | 102400 | ||
| 337626719 | anmichi | D | Sept. 8, 2025, 4:05 p.m. | OK | C++20 (GCC 13-64) | TESTS | 29 | 374 | 0 | ||
| 337631602 | HaramuraNodoka | D | Sept. 8, 2025, 4:15 p.m. | OK | C++20 (GCC 13-64) | TESTS | 29 | 406 | 204800 | ||
| 337693571 | wangjinbo | D | Sept. 9, 2025, 3:14 a.m. | OK | C++20 (GCC 13-64) | TESTS | 29 | 406 | 307200 | ||
| 337615302 | strapple | D | Sept. 8, 2025, 3:43 p.m. | OK | C++20 (GCC 13-64) | TESTS | 29 | 406 | 307200 | ||
| 337640906 | yeminghan | D | Sept. 8, 2025, 4:37 p.m. | OK | C++20 (GCC 13-64) | TESTS | 29 | 406 | 100556800 | ||
| 337627527 | Amoo_Safar | D | Sept. 8, 2025, 4:07 p.m. | OK | C++20 (GCC 13-64) | TESTS | 29 | 421 | 204800 | ||
| 337633204 | The_stardog | D | Sept. 8, 2025, 4:19 p.m. | OK | C++20 (GCC 13-64) | TESTS | 29 | 499 | 409600 | ||
| 337703618 | jiangbowen | D | Sept. 9, 2025, 5:37 a.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 29 | 202 | 204800 | ||
| 337620906 | OpGm | D | Sept. 8, 2025, 3:54 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 29 | 249 | 102400 | ||
| 337693287 | sarbansah0410 | D | Sept. 9, 2025, 3:10 a.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 29 | 280 | 102400 | ||
| 337619431 | Su_Zipei | D | Sept. 8, 2025, 3:51 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 29 | 296 | 102400 | ||
| 337676930 | catgirl | D | Sept. 8, 2025, 9:09 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 29 | 296 | 307200 | ||
| 337614716 | potato167 | D | Sept. 8, 2025, 3:42 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 29 | 311 | 102400 | ||
| 337647334 | tassei903 | D | Sept. 8, 2025, 4:54 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 29 | 312 | 102400 | ||
| 337693157 | Mitsukasa_Ayase | D | Sept. 9, 2025, 3:09 a.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 29 | 312 | 204800 | ||
| 337598453 | ecnerwala | D | Sept. 8, 2025, 3:16 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 29 | 327 | 0 | ||
| 337596493 | jiangly | D | Sept. 8, 2025, 3:13 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 29 | 327 | 0 | ||
| 337669752 | rainboy | D | Sept. 8, 2025, 7:31 p.m. | OK | GNU C11 | TESTS | 29 | 546 | 307200 | ||
| 337668531 | sunnydev | D | Sept. 8, 2025, 7:19 p.m. | OK | Java 8 | TESTS | 29 | 1561 | 0 | ||
| 337643820 | Tlatoani | D | Sept. 8, 2025, 4:45 p.m. | OK | Kotlin 2.2 | TESTS | 29 | 2890 | 1945600 | ||
| 337645977 | sansen | D | Sept. 8, 2025, 4:51 p.m. | OK | Rust 2021 | TESTS | 29 | 671 | 0 | ||
| 337617498 | Sugar_fan | D | Sept. 8, 2025, 3:47 p.m. | OK | Rust 2024 | TESTS | 29 | 1437 | 0 |
Back to search problems