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 |
---|---|---|---|---|---|---|
1132 | Educational Codeforces Round 61 (Rated for Div. 2) | FINISHED | False | 8100 | 185640887 | March 5, 2019, 3:05 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 1058 ) | G | Greedy Subsequences | PROGRAMMING | data structures dp trees | 2600 |
B"For some array c , let's denote a greedy subsequence as a sequence of indices p_1 , p_2 , ..., p_l such that 1 <= p_1 < p_2 < ... < p_l <= |c| , and for each i in [1, l - 1] , p_{i + 1} is the minimum number such that p_{i + 1} > p_i and c[p_{i + 1}] > c[p_i] . You are given an array a_1, a_2, ... , a_n . For each its subsegment of length k , calculate the length of its longest greedy subsequence. The first line contains two integers n and k ( 1 <= k <= n <= 10^6 ) -- the length of array a and the length of subsegments. The second line contains n integers a_1, a_2, ... , a_n ( 1 <= a_i <= n ) -- array a . Print n - k + 1 integers -- the maximum lengths of greedy subsequences of each subsegment having length k . The first number should correspond to subsegment a[1..k] , the second -- to subsegment a[2..k + 1] , and so on. In the first example: In the second example: "... |
T |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
57866823 | lopare | G | July 27, 2019, 9:41 p.m. | OK | GNU C++11 | TESTS | 57 | 296 | 39833600 | 2600 | |
57710682 | py_ultron | G | July 24, 2019, 11:31 p.m. | OK | GNU C++11 | TESTS | 57 | 296 | 39833600 | 2600 | |
53805659 | SoiMae | G | May 6, 2019, 12:17 a.m. | OK | GNU C++11 | TESTS | 57 | 296 | 86425600 | 2600 | |
64782991 | yzh666 | G | Nov. 13, 2019, 8:02 a.m. | OK | GNU C++11 | TESTS | 57 | 342 | 76288000 | 2600 | |
50878894 | danya090699 | G | March 6, 2019, 8:04 a.m. | OK | GNU C++11 | TESTS | 57 | 405 | 42291200 | 2600 | |
53381861 | Durant_Lee | G | April 26, 2019, 11:41 p.m. | OK | GNU C++11 | TESTS | 57 | 421 | 108236800 | 2600 | |
59333139 | WZYYN | G | Aug. 23, 2019, 2:43 a.m. | OK | GNU C++11 | TESTS | 57 | 436 | 44339200 | 2600 | |
51579026 | hk_cnyali | G | March 20, 2019, 1:52 p.m. | OK | GNU C++11 | TESTS | 57 | 451 | 80588800 | 2600 | |
51394287 | Bowen123 | G | March 17, 2019, 2:59 a.m. | OK | GNU C++11 | TESTS | 57 | 452 | 76595200 | 2600 | |
51394270 | luogu_bot3 | G | March 17, 2019, 2:58 a.m. | OK | GNU C++11 | TESTS | 57 | 452 | 76595200 | 2600 | |
52231387 | RNS_MHB | G | April 2, 2019, 12:02 p.m. | OK | GNU C++14 | TESTS | 57 | 327 | 40038400 | 2600 | |
52902247 | cloudsky01 | G | April 17, 2019, 11:30 a.m. | OK | GNU C++14 | TESTS | 57 | 342 | 40038400 | 2600 | |
51213372 | gyz_gyz | G | March 12, 2019, 9:09 a.m. | OK | GNU C++14 | TESTS | 57 | 358 | 29081600 | 2600 | |
51005180 | tmwilliamlin168 | G | March 8, 2019, 8:54 a.m. | OK | GNU C++14 | TESTS | 57 | 358 | 36044800 | 2600 | |
66566456 | malyna | G | Dec. 9, 2019, 10:44 p.m. | OK | GNU C++14 | TESTS | 57 | 623 | 134553600 | 2600 | |
51582483 | jerome_wei | G | March 20, 2019, 2:58 p.m. | OK | GNU C++14 | TESTS | 57 | 639 | 52121600 | 2600 | |
50874223 | dai | G | March 6, 2019, 5 a.m. | OK | GNU C++14 | TESTS | 57 | 685 | 58470400 | 2600 | |
50869549 | applese | G | March 5, 2019, 11:40 p.m. | OK | GNU C++14 | TESTS | 57 | 701 | 44441600 | 2600 | |
50923515 | ytriayggg | G | March 7, 2019, 10:38 a.m. | OK | GNU C++14 | TESTS | 57 | 701 | 97996800 | 2600 | |
53565057 | vjudge1 | G | April 30, 2019, 11:58 a.m. | OK | GNU C++14 | TESTS | 57 | 717 | 44134400 | 2600 | |
52267672 | vjudge5 | G | April 3, 2019, 11:59 a.m. | OK | GNU C++17 | TESTS | 57 | 343 | 29081600 | 2600 | |
51477902 | aleonov | G | March 19, 2019, 10 a.m. | OK | GNU C++17 | TESTS | 57 | 343 | 29081600 | 2600 | |
58638295 | dgklr | G | Aug. 12, 2019, 1:56 a.m. | OK | GNU C++17 | TESTS | 57 | 343 | 40038400 | 2600 | |
57169974 | vjudge3 | G | July 17, 2019, 2:24 a.m. | OK | GNU C++17 | TESTS | 57 | 358 | 40038400 | 2600 | |
50923766 | Charlene_Hao | G | March 7, 2019, 10:46 a.m. | OK | GNU C++17 | TESTS | 57 | 499 | 107008000 | 2600 | |
50995547 | bigbigbigcat111 | G | March 8, 2019, 3:20 a.m. | OK | GNU C++17 | TESTS | 57 | 608 | 102502400 | 2600 | |
50924700 | bigbigcat111 | G | March 7, 2019, 11:16 a.m. | OK | GNU C++17 | TESTS | 57 | 608 | 102502400 | 2600 | |
66566471 | vjudge2 | G | Dec. 9, 2019, 10:45 p.m. | OK | GNU C++17 | TESTS | 57 | 608 | 134553600 | 2600 | |
57190577 | vjudge3 | G | July 17, 2019, 10:25 a.m. | OK | GNU C++17 | TESTS | 57 | 717 | 40038400 | 2600 | |
51000712 | Megadeth | G | March 8, 2019, 6:39 a.m. | OK | GNU C++17 | TESTS | 57 | 717 | 44032000 | 2600 | |
51335786 | xodiac | G | March 15, 2019, 2:08 p.m. | OK | Java 8 | TESTS | 57 | 1029 | 38502400 | 2600 | |
66300873 | dalt | G | Dec. 5, 2019, 7:08 a.m. | OK | Java 8 | TESTS | 57 | 1481 | 133120000 | 2600 | |
51035582 | Jeel_Vaishnav | G | March 8, 2019, 3:01 p.m. | OK | Java 8 | TESTS | 57 | 1575 | 142848000 | 2600 | |
51048220 | SpargelTarzan | G | March 8, 2019, 7:38 p.m. | OK | Java 8 | TESTS | 57 | 1762 | 174796800 | 2600 | |
50876666 | just_soso | G | March 6, 2019, 6:37 a.m. | OK | Java 8 | TESTS | 57 | 1996 | 259379200 | 2600 | |
64291791 | vjudge1 | G | Nov. 5, 2019, 7:18 a.m. | OK | MS C++ | TESTS | 57 | 795 | 44134400 | 2600 | |
64517471 | vjudge3 | G | Nov. 8, 2019, 11:14 a.m. | OK | MS C++ 2017 | TESTS | 57 | 1512 | 32051200 | 2600 | |
50918932 | shivawu | G | March 7, 2019, 8:03 a.m. | OK | Rust | TESTS | 57 | 451 | 20787200 | 2600 |
Back to search problems