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 |
---|---|---|---|---|---|---|
1696 | Codeforces Global Round 21 | FINISHED | False | 8100 | 81012263 | June 25, 2022, 2:35 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 19042 ) | A | NIT orz! | PROGRAMMING | bitmasks greedy |
B'NIT, the cleaver, is new in town! Thousands of people line up to orz him. To keep his orzers entertained, NIT decided to let them solve the following problem related to operatorname{or} z . Can you solve this problem too? You are given a 1-indexed array of n integers, a , and an integer z . You can do the following operation any number (possibly zero) of times: Here operatorname{or} and operatorname{and} denote the bitwise operations OR and AND respectively. Find the maximum possible value of the maximum value in a after any number (possibly zero) of operations. Each test contains multiple test cases. The first line contains the number of test cases t ( 1 <= t <= 100 ). Description of the test cases follows. The first line of each test case contains two integers n and z ( 1 <= n <= 2000 , 0 <= z<2^{30} ). The second line of each test case contains n integers a_1 , a_2 , ldots , a_n ( 0 <= a_i<2^{30} ). It is guaranteed that the sum of n over all test cases does not exceed 10^4 . For each test case, print one integer -- the answer to the problem. In the first test case of the sample, one optimal sequence of operations is: After these operations, the sequence a becomes [3,7] , and the maximum value in it is 7 . We can prove that the maximum value in a can never exceed 7 , so the answer is 7 . In the fourth test case of the sample, one optimal sequence of operations is: '... |
Editorial of Codeforces Global Round 21 |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
161803993 | tgehr | A | June 25, 2022, 6:14 p.m. | OK | D | TESTS | 15 | 31 | 7782400 | ||
161789976 | XiaoDou | A | June 25, 2022, 4:24 p.m. | OK | GNU C11 | TESTS | 15 | 15 | 3686400 | ||
161790274 | Mostafizz | A | June 25, 2022, 4:25 p.m. | OK | GNU C11 | TESTS | 15 | 15 | 3686400 | ||
161794602 | prithwiraj_paul | A | June 25, 2022, 4:42 p.m. | OK | GNU C11 | TESTS | 15 | 15 | 3686400 | ||
161800891 | ajayrayjnvpp | A | June 25, 2022, 5:44 p.m. | OK | GNU C11 | TESTS | 15 | 15 | 3686400 | ||
161804107 | PialMahamudul | A | June 25, 2022, 6:15 p.m. | OK | GNU C11 | TESTS | 15 | 15 | 3686400 | ||
161804586 | PialMahamudul | A | June 25, 2022, 6:20 p.m. | OK | GNU C11 | TESTS | 15 | 15 | 3686400 | ||
161812023 | toblerone02 | A | June 25, 2022, 8:18 p.m. | OK | GNU C11 | TESTS | 15 | 15 | 3686400 | ||
161815065 | antuda | A | June 25, 2022, 9:30 p.m. | OK | GNU C11 | TESTS | 15 | 15 | 3686400 | ||
161804339 | PialMahamudul | A | June 25, 2022, 6:18 p.m. | OK | GNU C11 | TESTS | 15 | 30 | 3686400 | ||
161821179 | abusayeid | A | June 26, 2022, 1:24 a.m. | OK | GNU C11 | TESTS | 15 | 31 | 3686400 | ||
161822337 | strange757 | A | June 26, 2022, 2:03 a.m. | OK | GNU C++14 | TESTS | 15 | 0 | 1024000 | ||
161825197 | Mr__Peanutbutter | A | June 26, 2022, 3:24 a.m. | OK | GNU C++14 | TESTS | 15 | 15 | 1024000 | ||
161831043 | hardy_9795 | A | June 26, 2022, 5:38 a.m. | OK | GNU C++14 | TESTS | 15 | 15 | 1024000 | ||
161829989 | ishalgarg.19je0384 | A | June 26, 2022, 5:18 a.m. | OK | GNU C++14 | TESTS | 15 | 15 | 1024000 | ||
161829878 | yanchengzhi | A | June 26, 2022, 5:16 a.m. | OK | GNU C++14 | TESTS | 15 | 15 | 1024000 | ||
161828766 | the_conqueror_ | A | June 26, 2022, 4:53 a.m. | OK | GNU C++14 | TESTS | 15 | 15 | 1024000 | ||
161825472 | Tree2003 | A | June 26, 2022, 3:31 a.m. | OK | GNU C++14 | TESTS | 15 | 15 | 1024000 | ||
161824772 | jophyyjh | A | June 26, 2022, 3:13 a.m. | OK | GNU C++14 | TESTS | 15 | 15 | 1024000 | ||
161824492 | Jasper08 | A | June 26, 2022, 3:06 a.m. | OK | GNU C++14 | TESTS | 15 | 15 | 1024000 | ||
161824079 | LZOI_JURUO | A | June 26, 2022, 2:55 a.m. | OK | GNU C++14 | TESTS | 15 | 15 | 1024000 | ||
161832291 | ITACHII_UCHIHA | A | June 26, 2022, 6 a.m. | OK | GNU C++17 | TESTS | 15 | 15 | 1024000 | ||
161832295 | durgcoder | A | June 26, 2022, 6 a.m. | OK | GNU C++17 | TESTS | 15 | 15 | 1024000 | ||
161832351 | Anshuman_Maurya | A | June 26, 2022, 6:01 a.m. | OK | GNU C++17 | TESTS | 15 | 15 | 1024000 | ||
161830774 | DioPhanTous | A | June 26, 2022, 5:34 a.m. | OK | GNU C++17 | TESTS | 15 | 15 | 1024000 | ||
161830805 | Mr_Bin | A | June 26, 2022, 5:34 a.m. | OK | GNU C++17 | TESTS | 15 | 15 | 1024000 | ||
161830998 | abhimanyugr | A | June 26, 2022, 5:38 a.m. | OK | GNU C++17 | TESTS | 15 | 15 | 1024000 | ||
161831354 | wweverma1 | A | June 26, 2022, 5:45 a.m. | OK | GNU C++17 | TESTS | 15 | 15 | 1024000 | ||
161831401 | SzinAttila | A | June 26, 2022, 5:45 a.m. | OK | GNU C++17 | TESTS | 15 | 15 | 1024000 | ||
161831469 | vivekteja411 | A | June 26, 2022, 5:46 a.m. | OK | GNU C++17 | TESTS | 15 | 15 | 1024000 | ||
161831644 | Prahlad_Pawar | A | June 26, 2022, 5:50 a.m. | OK | GNU C++17 | TESTS | 15 | 15 | 1024000 | ||
161819923 | Chime | A | June 26, 2022, 12:34 a.m. | OK | GNU C++17 (64) | TESTS | 15 | 0 | 1228800 | ||
161830590 | jisanahmed10667 | A | June 26, 2022, 5:30 a.m. | OK | GNU C++17 (64) | TESTS | 15 | 15 | 1126400 | ||
161828287 | jaygaur99 | A | June 26, 2022, 4:42 a.m. | OK | GNU C++17 (64) | TESTS | 15 | 15 | 1228800 | ||
161830647 | elena44xx | A | June 26, 2022, 5:32 a.m. | OK | GNU C++17 (64) | TESTS | 15 | 15 | 1228800 | ||
161830355 | hemanshu02 | A | June 26, 2022, 5:26 a.m. | OK | GNU C++17 (64) | TESTS | 15 | 15 | 1228800 | ||
161830298 | Bananana. | A | June 26, 2022, 5:25 a.m. | OK | GNU C++17 (64) | TESTS | 15 | 15 | 1228800 | ||
161829988 | JKC_208 | A | June 26, 2022, 5:18 a.m. | OK | GNU C++17 (64) | TESTS | 15 | 15 | 1228800 | ||
161829862 | PCC | A | June 26, 2022, 5:16 a.m. | OK | GNU C++17 (64) | TESTS | 15 | 15 | 1228800 | ||
161829711 | jagerknight | A | June 26, 2022, 5:13 a.m. | OK | GNU C++17 (64) | TESTS | 15 | 15 | 1228800 | ||
161828503 | Lukman03 | A | June 26, 2022, 4:48 a.m. | OK | GNU C++17 (64) | TESTS | 15 | 15 | 1228800 | ||
161804327 | p.ferrari | A | June 25, 2022, 6:18 p.m. | OK | GNU C++20 (64) | TESTS | 15 | 0 | 1228800 | ||
161804019 | _0Istahak | A | June 25, 2022, 6:14 p.m. | OK | GNU C++20 (64) | TESTS | 15 | 0 | 1228800 | ||
161803766 | Anupam_Ghosh | A | June 25, 2022, 6:12 p.m. | OK | GNU C++20 (64) | TESTS | 15 | 0 | 1228800 | ||
161800488 | AndreyPavlov | A | June 25, 2022, 5:41 p.m. | OK | GNU C++20 (64) | TESTS | 15 | 0 | 1228800 | ||
161808842 | ashishkrg107 | A | June 25, 2022, 7:19 p.m. | OK | GNU C++20 (64) | TESTS | 15 | 0 | 1228800 | ||
161810364 | ramakp34 | A | June 25, 2022, 7:45 p.m. | OK | GNU C++20 (64) | TESTS | 15 | 0 | 1228800 | ||
161832094 | anandchourasia007 | A | June 26, 2022, 5:57 a.m. | OK | GNU C++20 (64) | TESTS | 15 | 0 | 1228800 | ||
161814194 | no_one1211 | A | June 25, 2022, 9:07 p.m. | OK | GNU C++20 (64) | TESTS | 15 | 0 | 1331200 | ||
161822074 | vipulkumar08 | A | June 26, 2022, 1:55 a.m. | OK | GNU C++20 (64) | TESTS | 15 | 0 | 1331200 | ||
161812982 | yaguar1337 | A | June 25, 2022, 8:38 p.m. | OK | GNU C++20 (64) | TESTS | 15 | 0 | 1331200 | ||
161816229 | moh.amr | A | June 25, 2022, 10:05 p.m. | OK | Go | TESTS | 15 | 15 | 4608000 | ||
161816268 | moh.amr | A | June 25, 2022, 10:06 p.m. | OK | Go | TESTS | 15 | 31 | 4608000 | ||
161824742 | Yelson | A | June 26, 2022, 3:12 a.m. | OK | Go | TESTS | 15 | 31 | 4812800 | ||
161814568 | satyaa_78 | A | June 25, 2022, 9:17 p.m. | OK | Java 11 | TESTS | 15 | 155 | 24985600 | ||
161831456 | poopoop | A | June 26, 2022, 5:46 a.m. | OK | Java 11 | TESTS | 15 | 156 | 25190400 | ||
161799985 | jyoti360 | A | June 25, 2022, 5:38 p.m. | OK | Java 11 | TESTS | 15 | 170 | 25088000 | ||
161815782 | lock_infinity | A | June 25, 2022, 9:52 p.m. | OK | Java 11 | TESTS | 15 | 171 | 25088000 | ||
161804058 | g_square | A | June 25, 2022, 6:15 p.m. | OK | Java 11 | TESTS | 15 | 171 | 25190400 | ||
161825188 | the_unseen | A | June 26, 2022, 3:23 a.m. | OK | Java 11 | TESTS | 15 | 171 | 25190400 | ||
161808181 | suhas5979 | A | June 25, 2022, 7:09 p.m. | OK | Java 11 | TESTS | 15 | 171 | 25190400 | ||
161821401 | iamavalon | A | June 26, 2022, 1:32 a.m. | OK | Java 11 | TESTS | 15 | 171 | 25497600 | ||
161808996 | prakharS-18 | A | June 25, 2022, 7:21 p.m. | OK | Java 11 | TESTS | 15 | 186 | 66560000 | ||
161815465 | dzhi | A | June 25, 2022, 9:43 p.m. | OK | Java 11 | TESTS | 15 | 187 | 25088000 | ||
161796513 | bhardwaj_sir | A | June 25, 2022, 4:48 p.m. | OK | Java 17 | TESTS | 15 | 202 | 40652800 | ||
161810638 | DylanSmith | A | June 25, 2022, 7:50 p.m. | OK | Java 8 | TESTS | 15 | 93 | 19353600 | ||
161799478 | amit_roy | A | June 25, 2022, 5:36 p.m. | OK | Java 8 | TESTS | 15 | 93 | 19353600 | ||
161816016 | ayafayed | A | June 25, 2022, 9:59 p.m. | OK | Java 8 | TESTS | 15 | 93 | 19353600 | ||
161815645 | Koka | A | June 25, 2022, 9:48 p.m. | OK | Java 8 | TESTS | 15 | 93 | 19353600 | ||
161811534 | abhinavTalesra | A | June 25, 2022, 8:08 p.m. | OK | Java 8 | TESTS | 15 | 93 | 19353600 | ||
161804977 | RONIN786 | A | June 25, 2022, 6:25 p.m. | OK | Java 8 | TESTS | 15 | 108 | 19353600 | ||
161800629 | Hajan | A | June 25, 2022, 5:42 p.m. | OK | Java 8 | TESTS | 15 | 109 | 19353600 | ||
161796466 | ShivanRawat19 | A | June 25, 2022, 4:48 p.m. | OK | Java 8 | TESTS | 15 | 109 | 19353600 | ||
161789456 | pavandandu | A | June 25, 2022, 4:22 p.m. | OK | Java 8 | TESTS | 15 | 124 | 19353600 | ||
161806920 | rish1896 | A | June 25, 2022, 6:50 p.m. | OK | Java 8 | TESTS | 15 | 124 | 19456000 | ||
161827959 | BruteForcee | A | June 26, 2022, 4:35 a.m. | OK | Kotlin 1.4 | TESTS | 15 | 140 | 21708800 | ||
161809192 | SlavaG | A | June 25, 2022, 7:24 p.m. | OK | Kotlin 1.6 | TESTS | 15 | 187 | 26009600 | ||
161813736 | bhawani0910 | A | June 25, 2022, 8:55 p.m. | OK | Kotlin 1.6 | TESTS | 15 | 202 | 26009600 | ||
161822082 | Lillian0701 | A | June 26, 2022, 1:55 a.m. | OK | MS C++ 2017 | TESTS | 15 | 15 | 1126400 | ||
161818828 | muhatmud | A | June 25, 2022, 11:46 p.m. | OK | MS C++ 2017 | TESTS | 15 | 15 | 1126400 | ||
161788457 | Janer | A | June 25, 2022, 4:18 p.m. | OK | MS C++ 2017 | TESTS | 15 | 31 | 1126400 | ||
161825390 | aaaabr1ck | A | June 26, 2022, 3:29 a.m. | OK | MS C++ 2017 | TESTS | 15 | 31 | 1126400 | ||
161804252 | rahul_Lalani_7 | A | June 25, 2022, 6:17 p.m. | OK | MS C++ 2017 | TESTS | 15 | 31 | 1126400 | ||
161787312 | cz_itsme | A | June 25, 2022, 4:14 p.m. | OK | MS C++ 2017 | TESTS | 15 | 31 | 1126400 | ||
161802767 | Mohmed_Salah | A | June 25, 2022, 6:01 p.m. | OK | MS C++ 2017 | TESTS | 15 | 31 | 1945600 | ||
161808046 | newbie27 | A | June 25, 2022, 7:07 p.m. | OK | Node.js | TESTS | 15 | 77 | 11776000 | ||
161804042 | Avirup_R | A | June 25, 2022, 6:15 p.m. | OK | PyPy 3 | TESTS | 15 | 77 | 20275200 | ||
161810108 | MohamedMidouni | A | June 25, 2022, 7:41 p.m. | OK | PyPy 3 | TESTS | 15 | 93 | 19865600 | ||
161786654 | vandr | A | June 25, 2022, 4:12 p.m. | OK | PyPy 3 | TESTS | 15 | 93 | 20070400 | ||
161826858 | MHAII | A | June 26, 2022, 4:09 a.m. | OK | PyPy 3 | TESTS | 15 | 93 | 20070400 | ||
161815540 | voicon | A | June 25, 2022, 9:44 p.m. | OK | PyPy 3 | TESTS | 15 | 93 | 20275200 | ||
161792390 | quandum | A | June 25, 2022, 4:34 p.m. | OK | PyPy 3 | TESTS | 15 | 108 | 19865600 | ||
161826912 | sfkn11 | A | June 26, 2022, 4:10 a.m. | OK | PyPy 3 | TESTS | 15 | 108 | 20070400 | ||
161807973 | ZH_twinkle | A | June 25, 2022, 7:06 p.m. | OK | PyPy 3 | TESTS | 15 | 108 | 20480000 | ||
161790200 | rasheed_ashen_one | A | June 25, 2022, 4:25 p.m. | OK | PyPy 3 | TESTS | 15 | 109 | 20377600 | ||
161820466 | grawlixes | A | June 26, 2022, 12:56 a.m. | OK | PyPy 3 | TESTS | 15 | 109 | 20684800 | ||
161830244 | simar0507 | A | June 26, 2022, 5:24 a.m. | OK | PyPy 3-64 | TESTS | 15 | 62 | 30924800 | ||
161801988 | sumit_athani | A | June 25, 2022, 5:53 p.m. | OK | PyPy 3-64 | TESTS | 15 | 62 | 31436800 | ||
161805789 | mayank35 | A | June 25, 2022, 6:35 p.m. | OK | PyPy 3-64 | TESTS | 15 | 62 | 31436800 | ||
161826311 | rajeshpenugonda6 | A | June 26, 2022, 3:54 a.m. | OK | PyPy 3-64 | TESTS | 15 | 62 | 31641600 | ||
161800240 | samchen123 | A | June 25, 2022, 5:40 p.m. | OK | PyPy 3-64 | TESTS | 15 | 77 | 31436800 | ||
161816085 | hsh8086 | A | June 25, 2022, 10:01 p.m. | OK | PyPy 3-64 | TESTS | 15 | 77 | 31436800 | ||
161801023 | Pronoy_Deb | A | June 25, 2022, 5:45 p.m. | OK | PyPy 3-64 | TESTS | 15 | 77 | 31436800 | ||
161800707 | sphoortimpatil | A | June 25, 2022, 5:42 p.m. | OK | PyPy 3-64 | TESTS | 15 | 77 | 31436800 | ||
161800282 | Versern | A | June 25, 2022, 5:40 p.m. | OK | PyPy 3-64 | TESTS | 15 | 77 | 31436800 | ||
161795167 | Myp001 | A | June 25, 2022, 4:44 p.m. | OK | PyPy 3-64 | TESTS | 15 | 77 | 31436800 | ||
161792527 | udayJan | A | June 25, 2022, 4:34 p.m. | OK | Python 3 | TESTS | 15 | 46 | 4812800 | ||
161830787 | ji-li-k | A | June 26, 2022, 5:34 a.m. | OK | Python 3 | TESTS | 15 | 46 | 4812800 | ||
161828775 | Ankush__Yadav | A | June 26, 2022, 4:53 a.m. | OK | Python 3 | TESTS | 15 | 46 | 4812800 | ||
161825825 | sakibrahman | A | June 26, 2022, 3:41 a.m. | OK | Python 3 | TESTS | 15 | 46 | 4812800 | ||
161819609 | Exclusion12 | A | June 26, 2022, 12:21 a.m. | OK | Python 3 | TESTS | 15 | 46 | 4812800 | ||
161807904 | Nivas2003 | A | June 25, 2022, 7:05 p.m. | OK | Python 3 | TESTS | 15 | 46 | 4812800 | ||
161803825 | Santhosh44 | A | June 25, 2022, 6:12 p.m. | OK | Python 3 | TESTS | 15 | 46 | 4812800 | ||
161801102 | ug201310015 | A | June 25, 2022, 5:46 p.m. | OK | Python 3 | TESTS | 15 | 46 | 4812800 | ||
161796112 | Saivivek_10 | A | June 25, 2022, 4:47 p.m. | OK | Python 3 | TESTS | 15 | 46 | 4812800 | ||
161791372 | Shishir.3xrd | A | June 25, 2022, 4:29 p.m. | OK | Python 3 | TESTS | 15 | 46 | 4812800 | ||
161805671 | utkarsh | A | June 25, 2022, 6:33 p.m. | OK | Ruby 3 | TESTS | 15 | 233 | 46796800 | ||
161805207 | sevensix | A | June 25, 2022, 6:28 p.m. | OK | Ruby 3 | TESTS | 15 | 265 | 46592000 | ||
161793072 | macosta | A | June 25, 2022, 4:36 p.m. | OK | Rust 2021 | TESTS | 15 | 15 | 1433600 | ||
161804171 | Thallium54 | A | June 25, 2022, 6:16 p.m. | OK | Rust 2021 | TESTS | 15 | 30 | 1433600 |
Back to search problems