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 |
---|---|---|---|---|---|---|
1360 | Codeforces Round 644 (Div. 3) | FINISHED | False | 7200 | 141495899 | May 24, 2020, 1:35 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 4599 ) | H | Binary Median | PROGRAMMING | bitmasks brute force constructive algorithms | 2100 |
B'Consider all binary strings of length m ( 1 <= m <= 60 ). A binary string is a string that consists of the characters 0 and 1 only. For example, 0110 is a binary string, and 012aba is not. Obviously, there are exactly 2^m such strings in total. The string s is lexicographically smaller than the string t (both have the same length m ) if in the first position i from the left in which they differ, we have s[i] < t[i] . This is exactly the way strings are compared in dictionaries and in most modern programming languages when comparing them in a standard way. For example, the string 01011 is lexicographically smaller than the string 01100, because the first two characters are the same, and the third character in the first string is less than that in the second. We remove from this set n ( 1 <= n <= min(2^m-1, 100) ) distinct binary strings a_1, a_2, ldots, a_n , each of length m . Thus, the set will have k=2^m-n strings. Sort all strings of the resulting set in lexicographical ascending order (as in the dictionary). We number all the strings after sorting from 0 to k-1 . Print the string whose index is lfloor frac{k-1}{2} rfloor (such an element is called median), where lfloor x rfloor is the rounding of the number down to the nearest integer. For example, if n=3 , m=3 and a=[ 010, 111, 001 ] , then after removing the strings a_i and sorting, the result will take the form: [ 000, 011, 100, 101, 110 ] . Thus, the desired median is 100. The first line contains an integer t ( 1 <= t <= 1000 ) -- the number of test cases. Then, t test cases follow. The first line of each test case contains integers n ( 1 <= n <= min(2^m-1, 100) ) and m ( 1 <= m <= 60 ), where n is the number of strings to remove, and m is the length of binary strings. The next n lines contain a_1'... |
Codeforces Round #644 (Div. 3) Editorial |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
81348353 | ruban | H | May 25, 2020, 5:07 a.m. | OK | Delphi | TESTS | 5 | 31 | 37376000 | 2100 | |
81656649 | day_dream | H | May 27, 2020, 9:39 p.m. | OK | GNU C++11 | TESTS | 5 | 15 | 0 | 2100 | |
81645203 | ACMonster | H | May 27, 2020, 5:43 p.m. | OK | GNU C++11 | TESTS | 5 | 15 | 0 | 2100 | |
81642248 | _Nice | H | May 27, 2020, 5:06 p.m. | OK | GNU C++11 | TESTS | 5 | 15 | 0 | 2100 | |
81641911 | kiomi | H | May 27, 2020, 5:02 p.m. | OK | GNU C++11 | TESTS | 5 | 15 | 0 | 2100 | |
81581262 | WWLDX | H | May 27, 2020, 4:54 a.m. | OK | GNU C++11 | TESTS | 5 | 15 | 0 | 2100 | |
81472572 | Vovsanka | H | May 26, 2020, 1:01 p.m. | OK | GNU C++11 | TESTS | 5 | 15 | 0 | 2100 | |
81470145 | harisaran | H | May 26, 2020, 12:31 p.m. | OK | GNU C++11 | TESTS | 5 | 15 | 0 | 2100 | |
81460514 | countercurrent-time | H | May 26, 2020, 10:34 a.m. | OK | GNU C++11 | TESTS | 5 | 15 | 0 | 2100 | |
81459734 | zzzyh | H | May 26, 2020, 10:23 a.m. | OK | GNU C++11 | TESTS | 5 | 15 | 0 | 2100 | |
81455477 | kartikey_21 | H | May 26, 2020, 9:25 a.m. | OK | GNU C++11 | TESTS | 5 | 15 | 0 | 2100 | |
81649972 | space_viking | H | May 27, 2020, 7:08 p.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | 2100 | |
81578602 | OTTFF | H | May 27, 2020, 4:02 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | 2100 | |
81474916 | KradecaNaLukcheta | H | May 26, 2020, 1:28 p.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | 2100 | |
81397840 | piledriver | H | May 25, 2020, 3:31 p.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | 2100 | |
81383774 | inder128 | H | May 25, 2020, 12:45 p.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | 2100 | |
81359197 | LM10_Piyush | H | May 25, 2020, 7:43 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | 2100 | |
81359047 | LM10_Piyush | H | May 25, 2020, 7:41 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | 2100 | |
81343610 | I_love_Ritumbhara | H | May 25, 2020, 3:19 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | 2100 | |
81667088 | nasadigital | H | May 28, 2020, 3:42 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 102400 | 2100 | |
81609150 | _AWM_ | H | May 27, 2020, 10:55 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 102400 | 2100 | |
81424727 | Wailydest | H | May 25, 2020, 10:51 p.m. | OK | GNU C++17 | TESTS | 5 | 15 | 0 | 2100 | |
81384418 | ashufarkya | H | May 25, 2020, 12:53 p.m. | OK | GNU C++17 | TESTS | 5 | 15 | 0 | 2100 | |
81701010 | hosein_bidaki | H | May 28, 2020, 11:43 a.m. | OK | GNU C++17 | TESTS | 5 | 15 | 102400 | 2100 | |
81562763 | ChEcKMatE_123 | H | May 26, 2020, 8:20 p.m. | OK | GNU C++17 | TESTS | 5 | 15 | 102400 | 2100 | |
81461830 | Ayushsaxena2 | H | May 26, 2020, 10:53 a.m. | OK | GNU C++17 | TESTS | 5 | 15 | 102400 | 2100 | |
81431663 | BrayanD | H | May 26, 2020, 3:03 a.m. | OK | GNU C++17 | TESTS | 5 | 15 | 102400 | 2100 | |
81425403 | quachtridat | H | May 25, 2020, 11:28 p.m. | OK | GNU C++17 | TESTS | 5 | 15 | 102400 | 2100 | |
81384348 | dadboss | H | May 25, 2020, 12:52 p.m. | OK | GNU C++17 | TESTS | 5 | 15 | 102400 | 2100 | |
81372787 | aslichoda | H | May 25, 2020, 10:34 a.m. | OK | GNU C++17 | TESTS | 5 | 15 | 102400 | 2100 | |
81342414 | mitsuri | H | May 25, 2020, 2:54 a.m. | OK | GNU C++17 | TESTS | 5 | 15 | 102400 | 2100 | |
81648125 | polpolpol | H | May 27, 2020, 6:46 p.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | 2100 | |
81642943 | tpoppo | H | May 27, 2020, 5:15 p.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | 2100 | |
81642839 | tpoppo | H | May 27, 2020, 5:13 p.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | 2100 | |
81642081 | Sisyy | H | May 27, 2020, 5:04 p.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | 2100 | |
81636798 | jesus_coconut | H | May 27, 2020, 4 p.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | 2100 | |
81630395 | handle_not_avail | H | May 27, 2020, 2:51 p.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | 2100 | |
81619464 | john__wick | H | May 27, 2020, 12:48 p.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | 2100 | |
81604336 | grand_zeno | H | May 27, 2020, 9:53 a.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | 2100 | |
81427110 | brunomont | H | May 26, 2020, 12:37 a.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | 2100 | |
81424009 | aryan005 | H | May 25, 2020, 10:20 p.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | 2100 | |
81329468 | Thallium_is_Vegetable | H | May 24, 2020, 7:50 p.m. | OK | Go | TESTS | 5 | 31 | 0 | 2100 | |
81334631 | clyring | H | May 24, 2020, 10:01 p.m. | OK | Haskell | TESTS | 5 | 30 | 102400 | 2100 | |
81474625 | jakejase2 | H | May 26, 2020, 1:25 p.m. | OK | Java 11 | TESTS | 5 | 171 | 0 | 2100 | |
81334035 | Piccadilly | H | May 24, 2020, 9:41 p.m. | OK | Java 11 | TESTS | 5 | 171 | 0 | 2100 | |
81471433 | sudhanshu_lucky | H | May 26, 2020, 12:47 p.m. | OK | Java 11 | TESTS | 5 | 186 | 0 | 2100 | |
81333369 | anhpp | H | May 24, 2020, 9:21 p.m. | OK | Java 11 | TESTS | 5 | 186 | 0 | 2100 | |
81332961 | Anonymous | H | May 24, 2020, 9:09 p.m. | OK | Java 11 | TESTS | 5 | 186 | 0 | 2100 | |
81446722 | avijit_agarwal | H | May 26, 2020, 7:28 a.m. | OK | Java 11 | TESTS | 5 | 187 | 0 | 2100 | |
81632289 | codingIsFun1234 | H | May 27, 2020, 3:10 p.m. | OK | Java 11 | TESTS | 5 | 249 | 0 | 2100 | |
81396935 | 533.sandyhu | H | May 25, 2020, 3:20 p.m. | OK | Java 11 | TESTS | 5 | 264 | 204800 | 2100 | |
81441338 | edwardsangam | H | May 26, 2020, 6:15 a.m. | OK | Java 8 | TESTS | 5 | 108 | 0 | 2100 | |
81416568 | zekigurbuz | H | May 25, 2020, 7:18 p.m. | OK | Java 8 | TESTS | 5 | 108 | 0 | 2100 | |
81391714 | cis_pie | H | May 25, 2020, 2:22 p.m. | OK | Java 8 | TESTS | 5 | 108 | 0 | 2100 | |
81343712 | tsumit023 | H | May 25, 2020, 3:22 a.m. | OK | Java 8 | TESTS | 5 | 108 | 0 | 2100 | |
81612576 | suraj99p | H | May 27, 2020, 11:36 a.m. | OK | Java 8 | TESTS | 5 | 109 | 0 | 2100 | |
81476311 | turing_fan123 | H | May 26, 2020, 1:45 p.m. | OK | Java 8 | TESTS | 5 | 109 | 0 | 2100 | |
81468293 | out_of_the_box | H | May 26, 2020, 12:15 p.m. | OK | Java 8 | TESTS | 5 | 109 | 0 | 2100 | |
81467248 | nidhigoel | H | May 26, 2020, 12:01 p.m. | OK | Java 8 | TESTS | 5 | 109 | 0 | 2100 | |
81467218 | The_Hidden_Man | H | May 26, 2020, 12:01 p.m. | OK | Java 8 | TESTS | 5 | 109 | 0 | 2100 | |
81524238 | horseprabhat625 | H | May 26, 2020, 3:42 p.m. | OK | Java 8 | TESTS | 5 | 109 | 0 | 2100 | |
81384162 | Fortin | H | May 25, 2020, 12:49 p.m. | OK | Kotlin | TESTS | 5 | 140 | 512000 | 2100 | |
81340109 | Igorjan94 | H | May 25, 2020, 1:50 a.m. | OK | Kotlin | TESTS | 5 | 186 | 0 | 2100 | |
81326325 | Traduttore | H | May 24, 2020, 6:54 p.m. | OK | Kotlin | TESTS | 5 | 187 | 0 | 2100 | |
81680179 | UD_xlinsist | H | May 28, 2020, 7:19 a.m. | OK | Kotlin | TESTS | 5 | 202 | 1228800 | 2100 | |
81407302 | avtoruxadze | H | May 25, 2020, 5:35 p.m. | OK | Mono C# | TESTS | 5 | 77 | 4812800 | 2100 | |
81338122 | Najmus_Sakib_Rashid | H | May 25, 2020, 12:35 a.m. | OK | MS C++ 2017 | TESTS | 5 | 30 | 0 | 2100 | |
81601073 | CrashMaster | H | May 27, 2020, 9:10 a.m. | OK | MS C++ 2017 | TESTS | 5 | 30 | 0 | 2100 | |
81431991 | 0Mordecai0 | H | May 26, 2020, 3:12 a.m. | OK | MS C++ 2017 | TESTS | 5 | 30 | 307200 | 2100 | |
81654333 | LSD | H | May 27, 2020, 8:33 p.m. | OK | MS C++ 2017 | TESTS | 5 | 31 | 0 | 2100 | |
81654145 | pratikjain226 | H | May 27, 2020, 8:28 p.m. | OK | PyPy 2 | TESTS | 5 | 140 | 1945600 | 2100 | |
81628313 | yumtam | H | May 27, 2020, 2:28 p.m. | OK | PyPy 2 | TESTS | 5 | 155 | 1638400 | 2100 | |
81424729 | ycui11 | H | May 25, 2020, 10:52 p.m. | OK | PyPy 2 | TESTS | 5 | 171 | 3072000 | 2100 | |
81399385 | raj1307 | H | May 25, 2020, 3:50 p.m. | OK | PyPy 2 | TESTS | 5 | 171 | 3584000 | 2100 | |
81576262 | mir.panov | H | May 27, 2020, 3:16 a.m. | OK | PyPy 2 | TESTS | 5 | 186 | 2355200 | 2100 | |
81399433 | raj1307 | H | May 25, 2020, 3:50 p.m. | OK | PyPy 2 | TESTS | 5 | 186 | 3584000 | 2100 | |
81436746 | bazzyadb | H | May 26, 2020, 5:02 a.m. | OK | PyPy 2 | TESTS | 5 | 233 | 2969600 | 2100 | |
81371515 | Anish1712 | H | May 25, 2020, 10:19 a.m. | OK | PyPy 2 | TESTS | 5 | 233 | 3584000 | 2100 | |
81371670 | Anish1712 | H | May 25, 2020, 10:20 a.m. | OK | PyPy 2 | TESTS | 5 | 233 | 3584000 | 2100 | |
81467918 | mo-hit | H | May 26, 2020, 12:10 p.m. | OK | PyPy 2 | TESTS | 5 | 248 | 10137600 | 2100 | |
81330553 | gintoki_s | H | May 24, 2020, 8:12 p.m. | OK | PyPy 3 | TESTS | 5 | 140 | 2355200 | 2100 | |
81417670 | jscn | H | May 25, 2020, 7:37 p.m. | OK | PyPy 3 | TESTS | 5 | 155 | 2457600 | 2100 | |
81424874 | damirych | H | May 25, 2020, 11 p.m. | OK | PyPy 3 | TESTS | 5 | 155 | 2662400 | 2100 | |
81332500 | gintoki_s | H | May 24, 2020, 8:57 p.m. | OK | PyPy 3 | TESTS | 5 | 155 | 2764800 | 2100 | |
81400161 | Arpanjain.g | H | May 25, 2020, 4 p.m. | OK | PyPy 3 | TESTS | 5 | 170 | 3481600 | 2100 | |
81470147 | shiv_99 | H | May 26, 2020, 12:31 p.m. | OK | PyPy 3 | TESTS | 5 | 170 | 3788800 | 2100 | |
81577677 | Coki628 | H | May 27, 2020, 3:43 a.m. | OK | PyPy 3 | TESTS | 5 | 171 | 3891200 | 2100 | |
81400474 | Arpanjain.g | H | May 25, 2020, 4:04 p.m. | OK | PyPy 3 | TESTS | 5 | 171 | 4198400 | 2100 | |
81642483 | smartron | H | May 27, 2020, 5:09 p.m. | OK | PyPy 3 | TESTS | 5 | 187 | 2764800 | 2100 | |
81335270 | emishun | H | May 24, 2020, 10:25 p.m. | OK | PyPy 3 | TESTS | 5 | 202 | 3174400 | 2100 | |
81661896 | yousef.nafea | H | May 28, 2020, 1:21 a.m. | OK | Python 3 | TESTS | 5 | 93 | 307200 | 2100 | |
81623772 | 17wh1a0532 | H | May 27, 2020, 1:38 p.m. | OK | Python 3 | TESTS | 5 | 93 | 307200 | 2100 | |
81446478 | vivanks | H | May 26, 2020, 7:24 a.m. | OK | Python 3 | TESTS | 5 | 93 | 307200 | 2100 | |
81330638 | gintoki_s | H | May 24, 2020, 8:13 p.m. | OK | Python 3 | TESTS | 5 | 93 | 307200 | 2100 | |
81478828 | venkat8332 | H | May 26, 2020, 2:16 p.m. | OK | Python 3 | TESTS | 5 | 108 | 307200 | 2100 | |
81388386 | ItayOtto | H | May 25, 2020, 1:40 p.m. | OK | Python 3 | TESTS | 5 | 108 | 307200 | 2100 | |
81356742 | mayank57 | H | May 25, 2020, 7:10 a.m. | OK | Python 3 | TESTS | 5 | 108 | 307200 | 2100 | |
81571111 | 340951987 | H | May 27, 2020, 12:57 a.m. | OK | Python 3 | TESTS | 5 | 109 | 307200 | 2100 | |
81431337 | misCHEVF | H | May 26, 2020, 2:55 a.m. | OK | Python 3 | TESTS | 5 | 109 | 307200 | 2100 | |
81357739 | mayank57 | H | May 25, 2020, 7:22 a.m. | OK | Python 3 | TESTS | 5 | 109 | 307200 | 2100 | |
81327677 | fatemender | H | May 24, 2020, 7:17 p.m. | OK | Rust | TESTS | 5 | 31 | 102400 | 2100 | |
81384545 | kobae964 | H | May 25, 2020, 12:54 p.m. | OK | Rust | TESTS | 5 | 31 | 307200 | 2100 |
Back to search problems