Educational Codeforces Round 70 (Rated for Div. 2)

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
1202 Educational Codeforces Round 70 (Rated for Div. 2) FINISHED False 7200 172250687 Aug. 7, 2019, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 9684 ) A You Are Given Two Binary Strings... PROGRAMMING bitmasks greedy 1100

B'You are given two binary strings x and y , which are binary representations of some two integers (let 's denote these integers as f(x) and f(y) ). You can choose any integer k ge 0 , calculate the expression s_k = f(x) + f(y) cdot 2^k and write the binary representation of s_k in reverse order (let 's denote it as rev_k ). For example, let x = 1010 and y = 11 ; you 've chosen k = 1 and, since 2^1 = 10_2 , so s_k = 1010_2 + 11_2 cdot 10_2 = 10000_2 and rev_k = 00001 . For given x and y , you need to choose such k that rev_k is lexicographically minimal (read notes if you don 't know what does "lexicographically" means). It 's guaranteed that, with given constraints, k exists and is finite. The first line contains a single integer T ( 1 <= T <= 100 ) -- the number of queries. Next 2T lines contain a description of queries: two lines per query. The first line contains one binary string x , consisting of no more than 10^5 characters. Each character is either 0 or 1. The second line contains one binary string y , consisting of no more than 10^5 characters. Each character is either 0 or 1. It 's guaranteed, that 1 <= f(y) <= f(x) (where f(x) is the integer represented by x , and f(y) is the integer represented by y ), both representations don 't have any leading zeroes, the total length of x over all queries doesn 't exceed 10^5 , and the total length of y over all queries doesn 't exceed 10^5 . Print T integers (one per query). For each query print such k that rev_k is lexicographically minimal. The first query was described in the legend. In the second query, it 's optimal to choose k = 3 . The 2^3 = 1000_2 so s_3 = 10001_2 + 110_2 cdot 1000_2 = 10001 + 110000 = 1000001 and rev_3 = 1000001 . For example, if k = 0 , then s_0'...

Tutorials

68972

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
58441636 daut-dlang A Aug. 7, 2019, 3:07 p.m. OK D TESTS 10 31 4198400 1100
58444681 Artemy1337 A Aug. 7, 2019, 3:26 p.m. OK Delphi TESTS 10 31 409600 1100
58449665 Arkady_E A Aug. 7, 2019, 3:55 p.m. OK Delphi TESTS 10 46 409600 1100
58444508 ti19_btvan A Aug. 7, 2019, 3:25 p.m. OK FPC TESTS 10 30 1126400 1100
58443140 naranja011223 A Aug. 7, 2019, 3:16 p.m. OK FPC TESTS 10 31 614400 1100
58446663 hengxin11111jy A Aug. 7, 2019, 3:37 p.m. OK FPC TESTS 10 31 1024000 1100
58441342 hua_xzx A Aug. 7, 2019, 3:06 p.m. OK FPC TESTS 10 31 1126400 1100
58449483 CH3CH2COOH A Aug. 7, 2019, 3:54 p.m. OK GNU C11 TESTS 10 15 204800 1100
58452512 coderbd A Aug. 7, 2019, 4:11 p.m. OK GNU C11 TESTS 10 15 204800 1100
58442350 ash070397 A Aug. 7, 2019, 3:12 p.m. OK GNU C11 TESTS 10 30 204800 1100
58440848 pengin_2000 A Aug. 7, 2019, 3:02 p.m. OK GNU C11 TESTS 10 31 204800 1100
58447141 malkiewiczm A Aug. 7, 2019, 3:40 p.m. OK GNU C11 TESTS 10 31 204800 1100
58453878 Kaidora A Aug. 7, 2019, 4:18 p.m. OK GNU C11 TESTS 10 31 204800 1100
58444387 Alfeh A Aug. 7, 2019, 3:24 p.m. OK GNU C11 TESTS 10 31 204800 1100
58440696 daixiahu A Aug. 7, 2019, 3:01 p.m. OK GNU C++11 TESTS 10 15 0 1100
58438814 zc_dalao A Aug. 7, 2019, 2:50 p.m. OK GNU C++11 TESTS 10 15 0 1100
58441063 Taday A Aug. 7, 2019, 3:04 p.m. OK GNU C++11 TESTS 10 15 204800 1100
58441272 Zachary_260325_cpp A Aug. 7, 2019, 3:05 p.m. OK GNU C++11 TESTS 10 15 204800 1100
58441375 _rango A Aug. 7, 2019, 3:06 p.m. OK GNU C++11 TESTS 10 15 204800 1100
58441750 Silver_Star A Aug. 7, 2019, 3:08 p.m. OK GNU C++11 TESTS 10 15 204800 1100
58441990 firstdove A Aug. 7, 2019, 3:10 p.m. OK GNU C++11 TESTS 10 15 204800 1100
58442077 hz2016 A Aug. 7, 2019, 3:10 p.m. OK GNU C++11 TESTS 10 15 204800 1100
58443704 wyhwyhwyhwyh A Aug. 7, 2019, 3:20 p.m. OK GNU C++11 TESTS 10 15 204800 1100
58448942 zhaoxupeng043202 A Aug. 7, 2019, 3:50 p.m. OK GNU C++11 TESTS 10 15 204800 1100
58442404 xvenom99 A Aug. 7, 2019, 3:12 p.m. OK GNU C++14 TESTS 10 15 204800 1100
58453051 Okazaki_Yumemi A Aug. 7, 2019, 4:14 p.m. OK GNU C++14 TESTS 10 15 204800 1100
58445431 melancholic_fat_otaku A Aug. 7, 2019, 3:30 p.m. OK GNU C++14 TESTS 10 15 204800 1100
58444777 tuananh238 A Aug. 7, 2019, 3:26 p.m. OK GNU C++14 TESTS 10 15 204800 1100
58443655 lvcunhan A Aug. 7, 2019, 3:20 p.m. OK GNU C++14 TESTS 10 15 204800 1100
58443469 SyrianTony A Aug. 7, 2019, 3:18 p.m. OK GNU C++14 TESTS 10 15 204800 1100
58443144 BumbleBee A Aug. 7, 2019, 3:16 p.m. OK GNU C++14 TESTS 10 15 204800 1100
58442237 haylee A Aug. 7, 2019, 3:11 p.m. OK GNU C++14 TESTS 10 15 204800 1100
58441386 GZhonghui A Aug. 7, 2019, 3:06 p.m. OK GNU C++14 TESTS 10 15 204800 1100
58441208 anthony1314 A Aug. 7, 2019, 3:05 p.m. OK GNU C++14 TESTS 10 15 204800 1100
58444154 TTTFU A Aug. 7, 2019, 3:23 p.m. OK GNU C++17 TESTS 10 15 204800 1100
58443757 Z_X_Y A Aug. 7, 2019, 3:20 p.m. OK GNU C++17 TESTS 10 15 204800 1100
58443346 ydh A Aug. 7, 2019, 3:18 p.m. OK GNU C++17 TESTS 10 15 204800 1100
58444160 W_A_S_I_F A Aug. 7, 2019, 3:23 p.m. OK GNU C++17 TESTS 10 15 204800 1100
58444556 kicwk A Aug. 7, 2019, 3:25 p.m. OK GNU C++17 TESTS 10 15 204800 1100
58444570 HA.wang A Aug. 7, 2019, 3:25 p.m. OK GNU C++17 TESTS 10 15 204800 1100
58445068 Janspiry A Aug. 7, 2019, 3:28 p.m. OK GNU C++17 TESTS 10 15 204800 1100
58447578 jianjia A Aug. 7, 2019, 3:43 p.m. OK GNU C++17 TESTS 10 15 204800 1100
58451716 shawwww A Aug. 7, 2019, 4:06 p.m. OK GNU C++17 TESTS 10 15 204800 1100
58453182 CYW_lyr A Aug. 7, 2019, 4:14 p.m. OK GNU C++17 TESTS 10 15 204800 1100
58444791 hypo A Aug. 7, 2019, 3:26 p.m. OK Go TESTS 10 31 0 1100
58438080 caidodo0_0 A Aug. 7, 2019, 2:45 p.m. OK Go TESTS 10 31 0 1100
58442164 zwwhdls A Aug. 7, 2019, 3:11 p.m. OK Go TESTS 10 46 0 1100
58437684 jmazon A Aug. 7, 2019, 2:41 p.m. OK Haskell TESTS 10 31 1126400 1100
58442877 anony9906 A Aug. 7, 2019, 3:15 p.m. OK Java 8 TESTS 10 93 0 1100
58440476 Naman_123 A Aug. 7, 2019, 3 p.m. OK Java 8 TESTS 10 93 0 1100
58439684 MohamedK A Aug. 7, 2019, 2:55 p.m. OK Java 8 TESTS 10 93 0 1100
58445296 1165MOHITSINGHAL A Aug. 7, 2019, 3:29 p.m. OK Java 8 TESTS 10 108 0 1100
58441893 Samez A Aug. 7, 2019, 3:09 p.m. OK Java 8 TESTS 10 108 0 1100
58441358 Rush___ A Aug. 7, 2019, 3:06 p.m. OK Java 8 TESTS 10 108 0 1100
58440947 nonatomicgames A Aug. 7, 2019, 3:03 p.m. OK Java 8 TESTS 10 108 0 1100
58440063 alex223 A Aug. 7, 2019, 2:58 p.m. OK Java 8 TESTS 10 108 0 1100
58439326 chojh1222 A Aug. 7, 2019, 2:53 p.m. OK Java 8 TESTS 10 108 0 1100
58438362 hhh12345 A Aug. 7, 2019, 2:47 p.m. OK Java 8 TESTS 10 108 0 1100
58443419 mongolrgata A Aug. 7, 2019, 3:18 p.m. OK JavaScript TESTS 10 46 5836800 1100
58449150 slemus A Aug. 7, 2019, 3:52 p.m. OK Kotlin TESTS 10 140 0 1100
58442166 sleepteam A Aug. 7, 2019, 3:11 p.m. OK Kotlin TESTS 10 202 1740800 1100
58438234 omikad A Aug. 7, 2019, 2:46 p.m. OK Mono C# TESTS 10 46 819200 1100
58441355 Giangvp A Aug. 7, 2019, 3:06 p.m. OK Mono C# TESTS 10 61 921600 1100
58440367 claw88 A Aug. 7, 2019, 2:59 p.m. OK Mono C# TESTS 10 61 5017600 1100
58448619 boomx A Aug. 7, 2019, 3:49 p.m. OK Mono C# TESTS 10 62 921600 1100
58442272 hibatibati A Aug. 7, 2019, 3:11 p.m. OK Mono C# TESTS 10 62 7270400 1100
58441616 eki A Aug. 7, 2019, 3:07 p.m. OK Mono C# TESTS 10 77 2355200 1100
58439233 keymoon A Aug. 7, 2019, 2:53 p.m. OK Mono C# TESTS 10 93 8192000 1100
58448479 Vetriti A Aug. 7, 2019, 3:48 p.m. OK MS C++ TESTS 10 15 409600 1100
58438957 wawahaha A Aug. 7, 2019, 2:51 p.m. OK MS C++ TESTS 10 30 204800 1100
58443733 qkm A Aug. 7, 2019, 3:20 p.m. OK MS C++ TESTS 10 31 204800 1100
58442181 kaguya_tsuki A Aug. 7, 2019, 3:11 p.m. OK MS C++ TESTS 10 31 204800 1100
58438796 jxf378440404 A Aug. 7, 2019, 2:50 p.m. OK MS C++ TESTS 10 31 204800 1100
58445379 munanzb... A Aug. 7, 2019, 3:30 p.m. OK MS C++ TESTS 10 31 204800 1100
58438697 TitorDong2333 A Aug. 7, 2019, 2:49 p.m. OK MS C++ TESTS 10 31 409600 1100
58439905 w616561153 A Aug. 7, 2019, 2:57 p.m. OK MS C++ TESTS 10 31 409600 1100
58444430 boa A Aug. 7, 2019, 3:24 p.m. OK MS C++ TESTS 10 31 409600 1100
58438095 math957963 A Aug. 7, 2019, 2:45 p.m. OK MS C++ TESTS 10 31 409600 1100
58439274 shijieshu A Aug. 7, 2019, 2:53 p.m. OK MS C++ 2017 TESTS 10 15 307200 1100
58440009 SiZK A Aug. 7, 2019, 2:57 p.m. OK MS C++ 2017 TESTS 10 15 307200 1100
58438912 Ivan11 A Aug. 7, 2019, 2:51 p.m. OK MS C++ 2017 TESTS 10 15 307200 1100
58442103 Yiii A Aug. 7, 2019, 3:10 p.m. OK MS C++ 2017 TESTS 10 15 307200 1100
58442607 The_Fiery_Soul A Aug. 7, 2019, 3:13 p.m. OK MS C++ 2017 TESTS 10 15 307200 1100
58439064 nvnulstu A Aug. 7, 2019, 2:52 p.m. OK MS C++ 2017 TESTS 10 15 819200 1100
58438759 GoFire A Aug. 7, 2019, 2:50 p.m. OK MS C++ 2017 TESTS 10 30 204800 1100
58438542 SakaRenko A Aug. 7, 2019, 2:48 p.m. OK MS C++ 2017 TESTS 10 30 204800 1100
58442233 lokolo A Aug. 7, 2019, 3:11 p.m. OK MS C++ 2017 TESTS 10 30 307200 1100
58453054 refined A Aug. 7, 2019, 4:14 p.m. OK MS C++ 2017 TESTS 10 30 307200 1100
58441938 Mukundan314 A Aug. 7, 2019, 3:09 p.m. OK PyPy 2 TESTS 10 109 1945600 1100
58439988 raj1307 A Aug. 7, 2019, 2:57 p.m. OK PyPy 2 TESTS 10 140 1945600 1100
58437696 alexwice A Aug. 7, 2019, 2:41 p.m. OK PyPy 2 TESTS 10 171 1638400 1100
58440531 marpetr A Aug. 7, 2019, 3:01 p.m. OK PyPy 2 TESTS 10 202 1228800 1100
58441819 andiso A Aug. 7, 2019, 3:09 p.m. OK PyPy 2 TESTS 10 873 7372800 1100
58438426 rickya A Aug. 7, 2019, 2:47 p.m. OK PyPy 3 TESTS 10 139 1126400 1100
58444637 Nil_Sinyaev A Aug. 7, 2019, 3:26 p.m. OK PyPy 3 TESTS 10 139 2355200 1100
58440956 nikeshthapa255 A Aug. 7, 2019, 3:03 p.m. OK PyPy 3 TESTS 10 139 2457600 1100
58440793 rajat_2548 A Aug. 7, 2019, 3:02 p.m. OK PyPy 3 TESTS 10 139 2457600 1100
58438437 rikein12 A Aug. 7, 2019, 2:47 p.m. OK PyPy 3 TESTS 10 140 2048000 1100
58446796 parthiv248 A Aug. 7, 2019, 3:38 p.m. OK PyPy 3 TESTS 10 140 2252800 1100
58446446 _nobody_ A Aug. 7, 2019, 3:36 p.m. OK PyPy 3 TESTS 10 140 2252800 1100
58440390 Stephan A Aug. 7, 2019, 3 p.m. OK PyPy 3 TESTS 10 140 2252800 1100
58438551 Q.E.D A Aug. 7, 2019, 2:48 p.m. OK PyPy 3 TESTS 10 140 2662400 1100
58446459 page_fault A Aug. 7, 2019, 3:36 p.m. OK PyPy 3 TESTS 10 140 2867200 1100
58446283 daniel.carlos A Aug. 7, 2019, 3:35 p.m. OK Python 2 TESTS 10 186 512000 1100
58444760 suhruth_3005 A Aug. 7, 2019, 3:26 p.m. OK Python 2 TESTS 10 202 2048000 1100
58439941 shehebe A Aug. 7, 2019, 2:57 p.m. OK Python 2 TESTS 10 217 409600 1100
58449392 Trishulya01 A Aug. 7, 2019, 3:53 p.m. OK Python 2 TESTS 10 218 512000 1100
58440096 ssk497 A Aug. 7, 2019, 2:58 p.m. OK Python 2 TESTS 10 249 5324800 1100
58443100 p1halani A Aug. 7, 2019, 3:16 p.m. OK Python 3 TESTS 10 108 614400 1100
58439349 tomzhangyx2 A Aug. 7, 2019, 2:53 p.m. OK Python 3 TESTS 10 109 512000 1100
58445624 dodge2 A Aug. 7, 2019, 3:31 p.m. OK Python 3 TESTS 10 109 614400 1100
58440528 xiaozhao A Aug. 7, 2019, 3:01 p.m. OK Python 3 TESTS 10 109 614400 1100
58440182 tadashiya A Aug. 7, 2019, 2:58 p.m. OK Python 3 TESTS 10 109 614400 1100
58439045 Sevlll A Aug. 7, 2019, 2:52 p.m. OK Python 3 TESTS 10 109 614400 1100
58438654 Mad_Andrei A Aug. 7, 2019, 2:49 p.m. OK Python 3 TESTS 10 109 614400 1100
58437918 spellstaker A Aug. 7, 2019, 2:44 p.m. OK Python 3 TESTS 10 109 614400 1100
58443266 yamatoumi A Aug. 7, 2019, 3:17 p.m. OK Python 3 TESTS 10 109 819200 1100
58455720 lucas.a A Aug. 7, 2019, 4:28 p.m. OK Python 3 TESTS 10 124 614400 1100
58455206 Kaidora A Aug. 7, 2019, 4:25 p.m. OK Ruby TESTS 10 77 819200 1100
58457152 BetBit A Aug. 7, 2019, 4:34 p.m. OK Rust TESTS 10 30 614400 1100
58437944 yakamoto A Aug. 7, 2019, 2:44 p.m. OK Scala TESTS 10 405 0 1100

remove filters

Back to search problems