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 |
---|---|---|---|---|---|---|
1552 | Codeforces Global Round 15 | FINISHED | False | 9900 | 104599499 | July 25, 2021, 2:35 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 1901 ) | E | Colors and Intervals | PROGRAMMING | constructive algorithms data structures greedy sortings |
B'The numbers 1, , 2, , ... , , n cdot k are colored with n colors. These colors are indexed by 1, , 2, , ... , , n . For each 1 <= i <= n , there are exactly k numbers colored with color i . Let [a, , b] denote the interval of integers between a and b inclusive, that is, the set {a, , a + 1, , ... , , b } . You must choose n intervals [a_1, , b_1], , [a_2, , b_2], , ... , [a_n, , b_n] such that: One can show that such a family of intervals always exists under the given constraints. The first line contains two integers n and k ( 1 <= n <= 100 , 2 <= k <= 100 ) -- the number of colors and the number of occurrences of each color. The second line contains n cdot k integers c_1, , c_2, , ... , , c_{nk} ( 1 <= c_j <= n ), where c_j is the color of number j . It is guaranteed that, for each 1 <= i <= n , it holds c_j = i for exactly k distinct indices j . Output n lines. The i -th line should contain the two integers a_i and b_i . If there are multiple valid choices of the intervals, output any. In the first sample, each number can be contained in at most <= ft lceil frac{4}{3 - 1} right rceil = 2 intervals. The output is described by the following picture: In the second sample, the only interval to be chosen is forced to be [1, , 2] , and each number is indeed contained in at most <= ft lceil frac{1}{2 - 1} right rceil = 1 interval. In the third sample, each number can be contained in at most <= ft lceil frac{3}{3 - 1} right rceil = 2 intervals. The output is described by the following picture: '... |
Editorial of Global Round 15 |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
123773270 | rainboy | E | July 25, 2021, 6:47 p.m. | OK | GNU C11 | TESTS | 62 | 31 | 3788800 | ||
123762382 | guapisolo | E | July 25, 2021, 5:01 p.m. | OK | GNU C++11 | TESTS | 62 | 30 | 3993600 | ||
123762693 | Serval | E | July 25, 2021, 5:03 p.m. | OK | GNU C++11 | TESTS | 62 | 31 | 3788800 | ||
123762082 | WDCnew | E | July 25, 2021, 5 p.m. | OK | GNU C++11 | TESTS | 62 | 31 | 3891200 | ||
123788649 | sorry-i-lost | E | July 26, 2021, 2 a.m. | OK | GNU C++11 | TESTS | 62 | 31 | 3993600 | ||
123787539 | Solashiro | E | July 26, 2021, 1:32 a.m. | OK | GNU C++11 | TESTS | 62 | 31 | 3993600 | ||
123786375 | __23333 | E | July 26, 2021, 12:59 a.m. | OK | GNU C++11 | TESTS | 62 | 31 | 3993600 | ||
123786318 | czyer | E | July 26, 2021, 12:58 a.m. | OK | GNU C++11 | TESTS | 62 | 31 | 3993600 | ||
123776358 | AQT | E | July 25, 2021, 7:41 p.m. | OK | GNU C++11 | TESTS | 62 | 31 | 3993600 | ||
123764787 | Dio | E | July 25, 2021, 5:11 p.m. | OK | GNU C++11 | TESTS | 62 | 31 | 3993600 | ||
123791839 | quanshr | E | July 26, 2021, 3:06 a.m. | OK | GNU C++11 | TESTS | 62 | 31 | 3993600 | ||
123758682 | axs7384 | E | July 25, 2021, 4:46 p.m. | OK | GNU C++14 | TESTS | 62 | 30 | 3891200 | ||
123770135 | mraron | E | July 25, 2021, 6:06 p.m. | OK | GNU C++14 | TESTS | 62 | 31 | 3788800 | ||
123763053 | elgamalsalman | E | July 25, 2021, 5:04 p.m. | OK | GNU C++14 | TESTS | 62 | 31 | 3788800 | ||
123762371 | Kaitokid | E | July 25, 2021, 5:01 p.m. | OK | GNU C++14 | TESTS | 62 | 31 | 3788800 | ||
123756922 | Mustang98 | E | July 25, 2021, 4:38 p.m. | OK | GNU C++14 | TESTS | 62 | 31 | 3788800 | ||
123774917 | TheOneYouWant | E | July 25, 2021, 7:15 p.m. | OK | GNU C++14 | TESTS | 62 | 31 | 3788800 | ||
123771596 | AlanSkarica | E | July 25, 2021, 6:23 p.m. | OK | GNU C++14 | TESTS | 62 | 31 | 3993600 | ||
123763376 | peehs_moorhsum | E | July 25, 2021, 5:06 p.m. | OK | GNU C++14 | TESTS | 62 | 31 | 3993600 | ||
123759541 | algodoer | E | July 25, 2021, 4:49 p.m. | OK | GNU C++14 | TESTS | 62 | 31 | 3993600 | ||
123774848 | amsraman | E | July 25, 2021, 7:14 p.m. | OK | GNU C++14 | TESTS | 62 | 31 | 3993600 | ||
123760158 | alex.y0675 | E | July 25, 2021, 4:52 p.m. | OK | GNU C++17 | TESTS | 62 | 30 | 3788800 | ||
123759585 | bvd | E | July 25, 2021, 4:49 p.m. | OK | GNU C++17 | TESTS | 62 | 30 | 3788800 | ||
123788516 | yy_nmy | E | July 26, 2021, 1:56 a.m. | OK | GNU C++17 | TESTS | 62 | 30 | 3788800 | ||
123762657 | Biot_DucToan | E | July 25, 2021, 5:03 p.m. | OK | GNU C++17 | TESTS | 62 | 30 | 4096000 | ||
123789963 | Fourthfour | E | July 26, 2021, 2:29 a.m. | OK | GNU C++17 | TESTS | 62 | 30 | 4403200 | ||
123759965 | sokian | E | July 25, 2021, 4:51 p.m. | OK | GNU C++17 | TESTS | 62 | 30 | 4608000 | ||
123800518 | XILEb | E | July 26, 2021, 5:49 a.m. | OK | GNU C++17 | TESTS | 62 | 31 | 3788800 | ||
123800229 | kunjan255 | E | July 26, 2021, 5:44 a.m. | OK | GNU C++17 | TESTS | 62 | 31 | 3788800 | ||
123800152 | kiranraj.kkb | E | July 26, 2021, 5:43 a.m. | OK | GNU C++17 | TESTS | 62 | 31 | 3788800 | ||
123786871 | mTvTm | E | July 26, 2021, 1:15 a.m. | OK | GNU C++17 | TESTS | 62 | 31 | 3788800 | ||
123758624 | dragonslayerintraining | E | July 25, 2021, 4:45 p.m. | OK | GNU C++17 (64) | TESTS | 62 | 15 | 4710400 | ||
123754054 | Osama_Alkhodairy | E | July 25, 2021, 4:26 p.m. | OK | GNU C++17 (64) | TESTS | 62 | 30 | 4300800 | ||
123758008 | johnathan79717 | E | July 25, 2021, 4:43 p.m. | OK | GNU C++17 (64) | TESTS | 62 | 30 | 4403200 | ||
123767337 | eidan | E | July 25, 2021, 5:19 p.m. | OK | GNU C++17 (64) | TESTS | 62 | 30 | 4403200 | ||
123765931 | Giada | E | July 25, 2021, 5:15 p.m. | OK | GNU C++17 (64) | TESTS | 62 | 30 | 4505600 | ||
123765844 | congthanh123 | E | July 25, 2021, 5:15 p.m. | OK | GNU C++17 (64) | TESTS | 62 | 30 | 4505600 | ||
123797813 | TabulaRasa7 | E | July 26, 2021, 5:04 a.m. | OK | GNU C++17 (64) | TESTS | 62 | 30 | 4505600 | ||
123766355 | Artyom123 | E | July 25, 2021, 5:16 p.m. | OK | GNU C++17 (64) | TESTS | 62 | 30 | 4915200 | ||
123779386 | dannyboy20031204 | E | July 25, 2021, 8:50 p.m. | OK | GNU C++17 (64) | TESTS | 62 | 31 | 4300800 | ||
123782268 | JaroslavUrban | E | July 25, 2021, 10:16 p.m. | OK | GNU C++17 (64) | TESTS | 62 | 31 | 4300800 | ||
123784010 | codelegend | E | July 25, 2021, 11:29 p.m. | OK | Haskell | TESTS | 62 | 46 | 12697600 | ||
123783852 | codelegend | E | July 25, 2021, 11:22 p.m. | OK | Haskell | TESTS | 62 | 46 | 12697600 | ||
123774285 | Dukkha | E | July 25, 2021, 7:04 p.m. | OK | Java 11 | TESTS | 62 | 202 | 23961600 | ||
123760491 | Justyo | E | July 25, 2021, 4:53 p.m. | OK | Java 11 | TESTS | 62 | 202 | 23961600 | ||
123763176 | mphillotry | E | July 25, 2021, 5:05 p.m. | OK | Java 11 | TESTS | 62 | 217 | 23961600 | ||
123760590 | dalt | E | July 25, 2021, 4:54 p.m. | OK | Java 11 | TESTS | 62 | 218 | 25088000 | ||
123764481 | martins | E | July 25, 2021, 5:10 p.m. | OK | Java 11 | TESTS | 62 | 233 | 24166400 | ||
123762331 | 2020akadaver | E | July 25, 2021, 5:01 p.m. | OK | Java 11 | TESTS | 62 | 233 | 24473600 | ||
123761837 | Discombobulated | E | July 25, 2021, 4:59 p.m. | OK | Java 11 | TESTS | 62 | 249 | 25395200 | ||
123773984 | Dukkha | E | July 25, 2021, 6:59 p.m. | OK | Java 11 | TESTS | 62 | 264 | 24678400 | ||
123760018 | hu_tao | E | July 25, 2021, 4:51 p.m. | OK | Java 8 | TESTS | 62 | 124 | 20377600 | ||
123765010 | NighTurs | E | July 25, 2021, 5:12 p.m. | OK | Java 8 | TESTS | 62 | 124 | 20480000 | ||
123787519 | SecondThread | E | July 26, 2021, 1:32 a.m. | OK | Java 8 | TESTS | 62 | 140 | 20377600 | ||
123755350 | SecondThread | E | July 25, 2021, 4:31 p.m. | OK | Java 8 | TESTS | 62 | 140 | 20377600 | ||
123757632 | pulkit1411 | E | July 25, 2021, 4:41 p.m. | OK | Java 8 | TESTS | 62 | 140 | 38502400 | ||
123763214 | Hakiobo | E | July 25, 2021, 5:05 p.m. | OK | Kotlin | TESTS | 62 | 124 | 20992000 | ||
123755544 | alexey.enkov | E | July 25, 2021, 4:32 p.m. | OK | Kotlin | TESTS | 62 | 171 | 21504000 | ||
123755441 | new_acc_ | E | July 25, 2021, 4:32 p.m. | OK | MS C++ 2017 | TESTS | 62 | 31 | 3891200 | ||
123762646 | titia | E | July 25, 2021, 5:02 p.m. | OK | PyPy 3 | TESTS | 62 | 156 | 25292800 | ||
123754963 | chinerist | E | July 25, 2021, 4:30 p.m. | OK | PyPy 3 | TESTS | 62 | 358 | 30924800 | ||
123763941 | cottoncotton | E | July 25, 2021, 5:08 p.m. | OK | Rust | TESTS | 62 | 46 | 3993600 |
Back to search problems