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 |
---|---|---|---|---|---|---|
1054 | Mail.Ru Cup 2018 Round 1 | FINISHED | False | 9000 | 197645123 | Oct. 18, 2018, 4:35 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 2281 ) | D | Changing Array | PROGRAMMING | greedy implementation | 1900 |
B'At a break Vanya came to the class and saw an array of n k -bit integers a_1, a_2, ldots, a_n on the board. An integer x is called a k -bit integer if 0 <= q x <= q 2^k - 1 . Of course, Vanya was not able to resist and started changing the numbers written on the board. To ensure that no one will note anything, Vanya allowed himself to make only one type of changes: choose an index of the array i ( 1 <= q i <= q n ) and replace the number a_i with the number overline{a_i} . We define overline{x} for a k -bit integer x as the k -bit integer such that all its k bits differ from the corresponding bits of x . Vanya does not like the number 0 . Therefore, he likes such segments [l, r] ( 1 <= q l <= q r <= q n ) such that a_l oplus a_{l+1} oplus ldots oplus a_r neq 0 , where oplus denotes the bitwise XOR operation. Determine the maximum number of segments he likes Vanya can get applying zero or more operations described above. The first line of the input contains two integers n and k ( 1 <= q n <= q 200 ,000 , 1 <= q k <= q 30 ). The next line contains n integers a_1, a_2, ldots, a_n ( 0 <= q a_i <= q 2^k - 1 ), separated by spaces -- the array of k -bit integers. Print one integer -- the maximum possible number of segments with XOR not equal to 0 that can be obtained by making several (possibly 0 ) operations described in the statement. In the first example if Vasya does not perform any operations, he gets an array that has 5 segments that Vanya likes. If he performs the operation with i = 2 , he gets an array [1, 0, 0] , because overline{3} = 0 when k = 2 . This array has 3 segments that Vanya likes. Also, to get an array with 5 segments that Vanya likes, he can perform two operations with i = 3 and with i = 2 . He then gets an arra'... |
Editorial |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
44508661 | Gassa | D | Oct. 18, 2018, 5:22 p.m. | OK | D | TESTS | 100 | 124 | 22425600 | 1900 | |
44514560 | fluffyowl | D | Oct. 18, 2018, 6:09 p.m. | OK | D | TESTS | 100 | 124 | 36147200 | 1900 | |
44957529 | SYury | D | Oct. 27, 2018, 2:59 p.m. | OK | GNU C11 | TESTS | 100 | 218 | 14643200 | 1900 | |
44884619 | SYury | D | Oct. 25, 2018, 8:57 p.m. | OK | GNU C11 | TESTS | 100 | 234 | 14643200 | 1900 | |
44884301 | SYury | D | Oct. 25, 2018, 8:45 p.m. | OK | GNU C11 | TESTS | 100 | 529 | 14643200 | 1900 | |
44907707 | luogu_bot1 | D | Oct. 26, 2018, 12:13 p.m. | OK | GNU C++11 | TESTS | 100 | 31 | 2764800 | 1900 | |
44903982 | luogu_bot4 | D | Oct. 26, 2018, 10:31 a.m. | OK | GNU C++11 | TESTS | 100 | 46 | 614400 | 1900 | |
56624464 | hk_cnyali | D | July 6, 2019, 1:13 p.m. | OK | GNU C++11 | TESTS | 100 | 46 | 819200 | 1900 | |
44907720 | luogu_bot2 | D | Oct. 26, 2018, 12:13 p.m. | OK | GNU C++11 | TESTS | 100 | 46 | 1638400 | 1900 | |
44907452 | luogu_bot2 | D | Oct. 26, 2018, 12:08 p.m. | OK | GNU C++11 | TESTS | 100 | 46 | 2764800 | 1900 | |
44906296 | luogu_bot3 | D | Oct. 26, 2018, 11:37 a.m. | OK | GNU C++11 | TESTS | 100 | 46 | 8806400 | 1900 | |
57170286 | hk_cnyali | D | July 17, 2019, 2:34 a.m. | OK | GNU C++11 | TESTS | 100 | 61 | 819200 | 1900 | |
44530738 | redbag | D | Oct. 19, 2018, 6:22 a.m. | OK | GNU C++11 | TESTS | 100 | 61 | 819200 | 1900 | |
50087807 | vjudge1 | D | Feb. 18, 2019, 8:33 a.m. | OK | GNU C++11 | TESTS | 100 | 61 | 3276800 | 1900 | |
44895287 | suncongbo | D | Oct. 26, 2018, 6:18 a.m. | OK | GNU C++11 | TESTS | 100 | 62 | 1433600 | 1900 | |
44516122 | albert0liu0 | D | Oct. 18, 2018, 6:25 p.m. | OK | GNU C++14 | TESTS | 100 | 62 | 819200 | 1900 | |
44751493 | ReaLNero1 | D | Oct. 23, 2018, 8:11 p.m. | OK | GNU C++14 | TESTS | 100 | 78 | 819200 | 1900 | |
44510538 | tesst | D | Oct. 18, 2018, 5:35 p.m. | OK | GNU C++14 | TESTS | 100 | 78 | 9523200 | 1900 | |
44539150 | Elegia | D | Oct. 19, 2018, 10:34 a.m. | OK | GNU C++14 | TESTS | 100 | 93 | 819200 | 1900 | |
44757008 | atoiz | D | Oct. 24, 2018, 3:29 a.m. | OK | GNU C++14 | TESTS | 100 | 93 | 819200 | 1900 | |
45474788 | VPigeonKing | D | Nov. 9, 2018, 11:56 a.m. | OK | GNU C++14 | TESTS | 100 | 93 | 819200 | 1900 | |
44513809 | krauch | D | Oct. 18, 2018, 6:02 p.m. | OK | GNU C++14 | TESTS | 100 | 93 | 1638400 | 1900 | |
44504244 | Subconscious | D | Oct. 18, 2018, 5 p.m. | OK | GNU C++14 | TESTS | 100 | 93 | 1638400 | 1900 | |
44507983 | skylinebaby | D | Oct. 18, 2018, 5:18 p.m. | OK | GNU C++14 | TESTS | 100 | 93 | 1740800 | 1900 | |
44507751 | georgerapeanu | D | Oct. 18, 2018, 5:17 p.m. | OK | GNU C++14 | TESTS | 100 | 93 | 2457600 | 1900 | |
44745390 | mihelifi | D | Oct. 23, 2018, 4:38 p.m. | OK | GNU C++17 | TESTS | 100 | 93 | 1024000 | 1900 | |
44560904 | usertab34 | D | Oct. 19, 2018, 7:32 p.m. | OK | GNU C++17 | TESTS | 100 | 93 | 1843200 | 1900 | |
44507643 | alex9801 | D | Oct. 18, 2018, 5:16 p.m. | OK | GNU C++17 | TESTS | 100 | 93 | 3481600 | 1900 | |
44507119 | antontrygubO_o | D | Oct. 18, 2018, 5:14 p.m. | OK | GNU C++17 | TESTS | 100 | 93 | 3481600 | 1900 | |
46515444 | nuip | D | Dec. 2, 2018, 3:53 p.m. | OK | GNU C++17 | TESTS | 100 | 93 | 10342400 | 1900 | |
44506977 | Lollipop | D | Oct. 18, 2018, 5:13 p.m. | OK | GNU C++17 | TESTS | 100 | 108 | 1024000 | 1900 | |
60172918 | 66990208 | D | Sept. 6, 2019, 1:33 p.m. | OK | GNU C++17 | TESTS | 100 | 108 | 3174400 | 1900 | |
46515414 | nuip | D | Dec. 2, 2018, 3:52 p.m. | OK | GNU C++17 | TESTS | 100 | 108 | 6758400 | 1900 | |
44533158 | PopescuMihai | D | Oct. 19, 2018, 7:33 a.m. | OK | GNU C++17 | TESTS | 100 | 108 | 7884800 | 1900 | |
69933526 | copperium | D | Feb. 1, 2020, 2:07 a.m. | OK | GNU C++17 | TESTS | 100 | 109 | 1638400 | 1900 | |
44505703 | uwi | D | Oct. 18, 2018, 5:07 p.m. | OK | Java 8 | TESTS | 100 | 155 | 2355200 | 1900 | |
44508940 | eatmore | D | Oct. 18, 2018, 5:24 p.m. | OK | Java 8 | TESTS | 100 | 187 | 9216000 | 1900 | |
44513970 | indy256 | D | Oct. 18, 2018, 6:04 p.m. | OK | Java 8 | TESTS | 100 | 202 | 0 | 1900 | |
44525824 | BaZ_ | D | Oct. 19, 2018, 2:20 a.m. | OK | Java 8 | TESTS | 100 | 217 | 8704000 | 1900 | |
44532898 | Codeforce_123 | D | Oct. 19, 2018, 7:26 a.m. | OK | Java 8 | TESTS | 100 | 218 | 10035200 | 1900 | |
44504696 | Lewin | D | Oct. 18, 2018, 5:02 p.m. | OK | Java 8 | TESTS | 100 | 233 | 10547200 | 1900 | |
44516960 | chandan5284 | D | Oct. 18, 2018, 6:34 p.m. | OK | Java 8 | TESTS | 100 | 233 | 10547200 | 1900 | |
44527833 | Psp_98 | D | Oct. 19, 2018, 4:23 a.m. | OK | Java 8 | TESTS | 100 | 233 | 10649600 | 1900 | |
44530167 | Srinivasa_Ramanujan | D | Oct. 19, 2018, 6:03 a.m. | OK | Java 8 | TESTS | 100 | 233 | 12185600 | 1900 | |
44598990 | wery0 | D | Oct. 20, 2018, 1:29 p.m. | OK | Java 8 | TESTS | 100 | 248 | 8601600 | 1900 | |
44508783 | alexey.enkov | D | Oct. 18, 2018, 5:23 p.m. | OK | Kotlin | TESTS | 100 | 452 | 20275200 | 1900 | |
44522819 | dinarisio | D | Oct. 18, 2018, 10:24 p.m. | OK | Mono C# | TESTS | 100 | 156 | 33792000 | 1900 | |
47905935 | claw88 | D | Jan. 4, 2019, 2:50 p.m. | OK | Mono C# | TESTS | 100 | 171 | 41881600 | 1900 | |
44537649 | omikad | D | Oct. 19, 2018, 9:46 a.m. | OK | Mono C# | TESTS | 100 | 171 | 43622400 | 1900 | |
44517857 | eki | D | Oct. 18, 2018, 6:45 p.m. | OK | Mono C# | TESTS | 100 | 826 | 33894400 | 1900 | |
44516217 | dolboeb | D | Oct. 18, 2018, 6:25 p.m. | OK | MS C++ | TESTS | 100 | 93 | 1638400 | 1900 | |
44508377 | wa1tz719 | D | Oct. 18, 2018, 5:20 p.m. | OK | MS C++ | TESTS | 100 | 156 | 8089600 | 1900 | |
45431819 | Houbunsha | D | Nov. 8, 2018, 4:30 a.m. | OK | MS C++ | TESTS | 100 | 234 | 14540800 | 1900 | |
44513141 | bayleef | D | Oct. 18, 2018, 5:56 p.m. | OK | MS C++ | TESTS | 100 | 249 | 13721600 | 1900 | |
69885952 | vjudge2 | D | Jan. 31, 2020, 8:12 a.m. | OK | MS C++ | TESTS | 100 | 280 | 13721600 | 1900 | |
44620022 | abtest100 | D | Oct. 21, 2018, 5:42 a.m. | OK | MS C++ | TESTS | 100 | 280 | 20172800 | 1900 | |
44556895 | artikot | D | Oct. 19, 2018, 5:47 p.m. | OK | MS C++ | TESTS | 100 | 295 | 12902400 | 1900 | |
69894008 | vjudge5 | D | Jan. 31, 2020, 11:07 a.m. | OK | MS C++ | TESTS | 100 | 296 | 14438400 | 1900 | |
69894118 | vjudge4 | D | Jan. 31, 2020, 11:09 a.m. | OK | MS C++ | TESTS | 100 | 311 | 13721600 | 1900 | |
69886887 | vjudge2 | D | Jan. 31, 2020, 8:33 a.m. | OK | MS C++ | TESTS | 100 | 311 | 19353600 | 1900 | |
44865131 | user202729_ | D | Oct. 25, 2018, 3:49 p.m. | OK | Perl | TESTS | 100 | 467 | 21094400 | 1900 | |
44509733 | alexwice | D | Oct. 18, 2018, 5:29 p.m. | OK | PyPy 2 | TESTS | 100 | 264 | 23142400 | 1900 | |
44667133 | kd710306 | D | Oct. 21, 2018, 6:36 p.m. | OK | PyPy 2 | TESTS | 100 | 265 | 25395200 | 1900 | |
44505507 | Onesh0t | D | Oct. 18, 2018, 5:06 p.m. | OK | PyPy 2 | TESTS | 100 | 280 | 19148800 | 1900 | |
44514151 | kal013 | D | Oct. 18, 2018, 6:05 p.m. | OK | PyPy 2 | TESTS | 100 | 280 | 23552000 | 1900 | |
44544998 | godmar | D | Oct. 19, 2018, 1:07 p.m. | OK | PyPy 2 | TESTS | 100 | 311 | 15667200 | 1900 | |
44545135 | godmar | D | Oct. 19, 2018, 1:10 p.m. | OK | PyPy 2 | TESTS | 100 | 312 | 16588800 | 1900 | |
44510704 | exoji2e | D | Oct. 18, 2018, 5:36 p.m. | OK | PyPy 2 | TESTS | 100 | 312 | 19968000 | 1900 | |
44563944 | godmar | D | Oct. 19, 2018, 9:09 p.m. | OK | PyPy 2 | TESTS | 100 | 342 | 15769600 | 1900 | |
44510687 | zacker-22 | D | Oct. 18, 2018, 5:36 p.m. | OK | PyPy 2 | TESTS | 100 | 358 | 33382400 | 1900 | |
44539870 | tsukuyomi | D | Oct. 19, 2018, 10:56 a.m. | OK | PyPy 3 | TESTS | 100 | 389 | 28160000 | 1900 | |
44506921 | La-Mariposa | D | Oct. 18, 2018, 5:13 p.m. | OK | PyPy 3 | TESTS | 100 | 390 | 28057600 | 1900 | |
44512994 | hellohell | D | Oct. 18, 2018, 5:55 p.m. | OK | Python 2 | TESTS | 100 | 717 | 19763200 | 1900 | |
48546514 | hmnid | D | Jan. 18, 2019, 7:55 p.m. | OK | Python 3 | TESTS | 100 | 467 | 18636800 | 1900 | |
44773545 | madn | D | Oct. 24, 2018, 1:22 p.m. | OK | Python 3 | TESTS | 100 | 483 | 18534400 | 1900 | |
44518261 | Savit_Gupta | D | Oct. 18, 2018, 6:50 p.m. | OK | Python 3 | TESTS | 100 | 530 | 30208000 | 1900 | |
45205135 | bupt.wc | D | Nov. 2, 2018, 12:19 p.m. | OK | Python 3 | TESTS | 100 | 545 | 18739200 | 1900 | |
44516547 | hop-hop | D | Oct. 18, 2018, 6:29 p.m. | OK | Python 3 | TESTS | 100 | 545 | 19660800 | 1900 | |
46942246 | whatshisbucket | D | Dec. 12, 2018, 5:22 p.m. | OK | Python 3 | TESTS | 100 | 592 | 17715200 | 1900 | |
59549696 | NocturneBflat | D | Aug. 27, 2019, 1:53 a.m. | OK | Python 3 | TESTS | 100 | 592 | 19558400 | 1900 | |
44907681 | kp1999 | D | Oct. 26, 2018, 12:12 p.m. | OK | Python 3 | TESTS | 100 | 670 | 30208000 | 1900 | |
44530732 | Grevozin | D | Oct. 19, 2018, 6:22 a.m. | OK | Rust | TESTS | 100 | 140 | 12083200 | 1900 |
Back to search problems