Codeforces Round 634 (Div. 3)

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
1335 Codeforces Round 634 (Div. 3) FINISHED False 7200 145034699 April 13, 2020, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 38719 ) B Construct the String PROGRAMMING constructive algorithms 1000

B'You are given three positive integers n , a and b . You have to construct a string s of length n consisting of lowercase Latin letters such that each substring of length a has exactly b distinct letters. It is guaranteed that the answer exists. You have to answer t independent test cases. Recall that the substring s[l ... r] is the string s_l, s_{l+1}, ... , s_{r} and its length is r - l + 1 . In this problem you are only interested in substrings of length a . The first line of the input contains one integer t ( 1 <= t <= 2000 ) -- the number of test cases. Then t test cases follow. The only line of a test case contains three space-separated integers n , a and b ( 1 <= a <= n <= 2000, 1 <= b <= min(26, a) ), where n is the length of the required string, a is the length of a substring and b is the required number of distinct letters in each substring of length a . It is guaranteed that the sum of n over all test cases does not exceed 2000 ( sum n <= 2000 ). For each test case, print the answer -- such a string s of length n consisting of lowercase Latin letters that each substring of length a has exactly b distinct letters. If there are multiple valid answers, print any of them. It is guaranteed that the answer exists. In the first test case of the example, consider all the substrings of length 5 : '...

Tutorials

75993

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
76765421 rahul5720 B April 15, 2020, 6:46 a.m. OK Clang++17 Diagnostics TESTS 24 31 0 1000
77572559 ar137375 B April 21, 2020, 5:02 p.m. OK Clang++17 Diagnostics TESTS 24 46 0 1000
77464324 vjudge3 B April 21, 2020, 12:11 p.m. OK Clang++17 Diagnostics TESTS 24 46 0 1000
76775628 mahfuzz B April 15, 2020, 8:40 a.m. OK Clang++17 Diagnostics TESTS 24 46 0 1000
76790116 vjudge4 B April 15, 2020, 11:29 a.m. OK Clang++17 Diagnostics TESTS 24 46 0 1000
77236913 vjudge2 B April 19, 2020, 4 a.m. OK Clang++17 Diagnostics TESTS 24 46 0 1000
76654226 kankichi B April 14, 2020, 3:42 a.m. OK Clang++17 Diagnostics TESTS 24 46 6246400 1000
76755473 vvr40978 B April 15, 2020, 4:11 a.m. OK FPC TESTS 24 31 0 1000
76695789 Rusu_Daniela B April 14, 2020, 1:12 p.m. OK FPC TESTS 24 46 102400 1000
76992215 prathamesh30 B April 16, 2020, 3:55 p.m. OK GNU C11 TESTS 24 15 0 1000
77172268 Biuasm B April 18, 2020, 10:55 a.m. OK GNU C11 TESTS 24 30 0 1000
77718583 yigezhe B April 23, 2020, 6:24 a.m. OK GNU C11 TESTS 24 30 0 1000
76676601 edith007 B April 14, 2020, 10:04 a.m. OK GNU C11 TESTS 24 30 0 1000
77957549 cercatrova B April 24, 2020, 9:04 p.m. OK GNU C11 TESTS 24 31 0 1000
77982410 nk.ramakrishnan B April 25, 2020, 6:19 a.m. OK GNU C11 TESTS 24 31 0 1000
77683307 ceamin_cste B April 22, 2020, 6:10 p.m. OK GNU C11 TESTS 24 31 0 1000
77672776 JF_ALVE B April 22, 2020, 4:23 p.m. OK GNU C11 TESTS 24 31 0 1000
77691307 Rittamdas B April 22, 2020, 7:51 p.m. OK GNU C11 TESTS 24 31 0 1000
77892632 Nivedha_LS B April 24, 2020, 8:19 a.m. OK GNU C11 TESTS 24 31 0 1000
77965708 OscarGauss B April 25, 2020, 12:39 a.m. OK GNU C++11 TESTS 24 15 0 1000
77673145 siddhant2001 B April 22, 2020, 4:26 p.m. OK GNU C++11 TESTS 24 15 0 1000
77446475 FatCatYcc B April 21, 2020, 8:45 a.m. OK GNU C++11 TESTS 24 15 0 1000
77135550 init0xyz B April 18, 2020, 2:09 a.m. OK GNU C++11 TESTS 24 15 0 1000
76994465 ek_skywalker B April 16, 2020, 4:16 p.m. OK GNU C++11 TESTS 24 15 0 1000
76971201 14727629331 B April 16, 2020, 12:43 p.m. OK GNU C++11 TESTS 24 15 0 1000
76785356 Dipu_MBSTU B April 15, 2020, 10:33 a.m. OK GNU C++11 TESTS 24 15 0 1000
76784441 Dipu_MBSTU B April 15, 2020, 10:20 a.m. OK GNU C++11 TESTS 24 15 0 1000
76755333 strong_independent_woman B April 15, 2020, 4:08 a.m. OK GNU C++11 TESTS 24 15 0 1000
76735555 tmoney99 B April 14, 2020, 7:58 p.m. OK GNU C++11 TESTS 24 15 0 1000
77284281 WildArchmage B April 19, 2020, 2:27 p.m. OK GNU C++14 TESTS 24 15 0 1000
77287755 Jingyui B April 19, 2020, 3:04 p.m. OK GNU C++14 TESTS 24 15 0 1000
77300610 4yush933 B April 19, 2020, 5:43 p.m. OK GNU C++14 TESTS 24 15 0 1000
77331152 Nityesh_mt02 B April 20, 2020, 6:15 a.m. OK GNU C++14 TESTS 24 15 0 1000
77411511 stark_28 B April 20, 2020, 9:19 p.m. OK GNU C++14 TESTS 24 15 0 1000
77583744 darknova B April 21, 2020, 7:07 p.m. OK GNU C++14 TESTS 24 15 0 1000
77589924 pasha009 B April 21, 2020, 8:46 p.m. OK GNU C++14 TESTS 24 15 0 1000
77813104 kapilsharma1998 B April 23, 2020, 3:43 p.m. OK GNU C++14 TESTS 24 15 0 1000
77813219 toyon1 B April 23, 2020, 3:43 p.m. OK GNU C++14 TESTS 24 15 0 1000
77928688 agarwala2512 B April 24, 2020, 3:20 p.m. OK GNU C++14 TESTS 24 15 0 1000
77355058 _deep_m_ B April 20, 2020, 11:39 a.m. OK GNU C++17 TESTS 24 15 0 1000
77897001 Arshit_Mangukiya B April 24, 2020, 9:11 a.m. OK GNU C++17 TESTS 24 15 0 1000
77795792 pavansai006 B April 23, 2020, 3:15 p.m. OK GNU C++17 TESTS 24 15 0 1000
77691458 drish1001 B April 22, 2020, 7:54 p.m. OK GNU C++17 TESTS 24 15 0 1000
77642283 c_only B April 22, 2020, noon OK GNU C++17 TESTS 24 15 0 1000
77591954 Munna555 B April 21, 2020, 9:27 p.m. OK GNU C++17 TESTS 24 15 0 1000
77453908 Sreekanth25 B April 21, 2020, 10:17 a.m. OK GNU C++17 TESTS 24 15 0 1000
77438871 KekriCoder B April 21, 2020, 7:05 a.m. OK GNU C++17 TESTS 24 15 0 1000
77438808 pitkeri B April 21, 2020, 7:04 a.m. OK GNU C++17 TESTS 24 15 0 1000
77309119 Mohamed-Mostafa B April 19, 2020, 7:51 p.m. OK GNU C++17 TESTS 24 15 0 1000
76823947 rockoanna B April 15, 2020, 2:48 p.m. OK GNU C++17 (64) TESTS 24 15 0 1000
76939624 Gornak40 B April 16, 2020, 7:11 a.m. OK GNU C++17 (64) TESTS 24 15 0 1000
76986943 pradnesh B April 16, 2020, 3:08 p.m. OK GNU C++17 (64) TESTS 24 15 0 1000
77401208 cseamangarg B April 20, 2020, 7:23 p.m. OK GNU C++17 (64) TESTS 24 15 0 1000
77416193 blackomega B April 20, 2020, 11:34 p.m. OK GNU C++17 (64) TESTS 24 15 0 1000
77416251 blackomega B April 20, 2020, 11:37 p.m. OK GNU C++17 (64) TESTS 24 15 0 1000
77648977 _Black_RM_Diamond_ B April 22, 2020, 1:09 p.m. OK GNU C++17 (64) TESTS 24 15 0 1000
77761589 cu.18bcs2174 B April 23, 2020, 2:02 p.m. OK GNU C++17 (64) TESTS 24 15 0 1000
77902009 growthless B April 24, 2020, 10:29 a.m. OK GNU C++17 (64) TESTS 24 15 0 1000
77998622 Gurseerat_Kaur B April 25, 2020, 8:40 a.m. OK GNU C++17 (64) TESTS 24 15 0 1000
77130524 vchilikov B April 17, 2020, 11:08 p.m. OK Go TESTS 24 31 0 1000
76657195 sonlh07 B April 14, 2020, 4:34 a.m. OK Go TESTS 24 31 0 1000
77130585 vchilikov B April 17, 2020, 11:10 p.m. OK Go TESTS 24 46 102400 1000
76944874 amit_839 B April 16, 2020, 8:07 a.m. OK Go TESTS 24 46 102400 1000
77475297 amsuper B April 21, 2020, 2:05 p.m. OK Haskell TESTS 24 31 102400 1000
77102871 XOR-star B April 17, 2020, 4:51 p.m. OK Haskell TESTS 24 46 102400 1000
77143046 kelvinc1024 B April 18, 2020, 5:09 a.m. OK Java 11 TESTS 24 171 0 1000
76773898 p_unit B April 15, 2020, 8:22 a.m. OK Java 11 TESTS 24 171 0 1000
76760063 kronos12345 B April 15, 2020, 5:35 a.m. OK Java 11 TESTS 24 171 0 1000
76736992 ankit2744 B April 14, 2020, 8:21 p.m. OK Java 11 TESTS 24 171 0 1000
76734151 sajith B April 14, 2020, 7:40 p.m. OK Java 11 TESTS 24 171 0 1000
76998224 mikkk B April 16, 2020, 4:56 p.m. OK Java 11 TESTS 24 186 0 1000
77121091 XsLel B April 17, 2020, 7:59 p.m. OK Java 11 TESTS 24 187 0 1000
76974599 hadron B April 16, 2020, 1:17 p.m. OK Java 11 TESTS 24 187 0 1000
76758398 enricogi B April 15, 2020, 5:07 a.m. OK Java 11 TESTS 24 187 0 1000
76726843 maheshwari_madhav B April 14, 2020, 6:13 p.m. OK Java 11 TESTS 24 187 0 1000
76692630 fang9 B April 14, 2020, 12:40 p.m. OK Java 8 TESTS 24 108 0 1000
77386183 lallantop B April 20, 2020, 5:02 p.m. OK Java 8 TESTS 24 108 0 1000
77313133 csullivan203 B April 19, 2020, 9:18 p.m. OK Java 8 TESTS 24 108 0 1000
77309585 harshitContest B April 19, 2020, 8 p.m. OK Java 8 TESTS 24 108 0 1000
78009152 rihaz_zahir B April 25, 2020, 9:44 a.m. OK Java 8 TESTS 24 109 0 1000
77943389 TheJormungandr B April 24, 2020, 5:50 p.m. OK Java 8 TESTS 24 109 0 1000
77612218 sanskriti0512 B April 22, 2020, 6:25 a.m. OK Java 8 TESTS 24 109 0 1000
77427366 Priyank B April 21, 2020, 5:08 a.m. OK Java 8 TESTS 24 109 0 1000
77323926 vjudge2 B April 20, 2020, 3:38 a.m. OK Java 8 TESTS 24 109 0 1000
77313638 nidhigoel B April 19, 2020, 9:32 p.m. OK Java 8 TESTS 24 109 0 1000
77619613 191110899 B April 22, 2020, 7:54 a.m. OK JavaScript TESTS 24 46 102400 1000
77383313 jhonber B April 20, 2020, 4:23 p.m. OK JavaScript TESTS 24 46 102400 1000
76698424 arpit2438735 B April 14, 2020, 1:35 p.m. OK JavaScript TESTS 24 62 102400 1000
77057999 Spheniscine B April 17, 2020, 9:51 a.m. OK Kotlin TESTS 24 124 0 1000
76697855 slemus B April 14, 2020, 1:30 p.m. OK Kotlin TESTS 24 124 0 1000
77546986 FireCloudEvilGod B April 21, 2020, 3:57 p.m. OK Kotlin TESTS 24 139 0 1000
76958188 david_varela B April 16, 2020, 10:34 a.m. OK Kotlin TESTS 24 139 0 1000
77537328 FireCloudEvilGod B April 21, 2020, 3:40 p.m. OK Kotlin TESTS 24 140 0 1000
76958551 david_varela B April 16, 2020, 10:37 a.m. OK Kotlin TESTS 24 140 0 1000
76770296 taresin B April 15, 2020, 7:42 a.m. OK Kotlin TESTS 24 155 0 1000
77174416 nikitos111 B April 18, 2020, 11:18 a.m. OK Mono C# TESTS 24 46 0 1000
76724122 Efrocinya B April 14, 2020, 5:45 p.m. OK Mono C# TESTS 24 46 2969600 1000
77415905 la_rasu B April 20, 2020, 11:22 p.m. OK Mono C# TESTS 24 61 0 1000
77797363 Nirushuu B April 23, 2020, 3:17 p.m. OK Mono C# TESTS 24 61 2969600 1000
77185444 GusztavSzmolik B April 18, 2020, 1:16 p.m. OK Mono C# TESTS 24 62 0 1000
76652638 Dineshraj B April 14, 2020, 3:13 a.m. OK Mono C# TESTS 24 62 2969600 1000
76673433 TRR B April 14, 2020, 9:32 a.m. OK Mono C# TESTS 24 77 0 1000
77601933 szzz- B April 22, 2020, 2:33 a.m. OK Mono C# TESTS 24 77 102400 1000
76727365 Anji B April 14, 2020, 6:19 p.m. OK Mono C# TESTS 24 77 3584000 1000
76983576 Satosi B April 16, 2020, 2:40 p.m. OK Mono C# TESTS 24 77 3686400 1000
76789440 vjudge3 B April 15, 2020, 11:22 a.m. OK MS C++ TESTS 24 31 0 1000
77320180 vjudge3 B April 20, 2020, 1:33 a.m. OK MS C++ TESTS 24 31 0 1000
77610620 LolLoDaffy B April 22, 2020, 5:55 a.m. OK MS C++ TESTS 24 31 0 1000
76689935 kapil16garg B April 14, 2020, 12:16 p.m. OK MS C++ 2017 TESTS 24 30 0 1000
77649880 nalin_9 B April 22, 2020, 1:18 p.m. OK MS C++ 2017 TESTS 24 31 0 1000
77667028 omerb.zeybek B April 22, 2020, 3:32 p.m. OK MS C++ 2017 TESTS 24 31 0 1000
77769167 s2297247423 B April 23, 2020, 2:47 p.m. OK MS C++ 2017 TESTS 24 31 0 1000
77923008 HD2000 B April 24, 2020, 2:32 p.m. OK MS C++ 2017 TESTS 24 31 0 1000
77477785 suVrik B April 21, 2020, 2:30 p.m. OK MS C++ 2017 TESTS 24 31 0 1000
77472508 vjudge3 B April 21, 2020, 1:37 p.m. OK MS C++ 2017 TESTS 24 31 0 1000
77458215 landfakira B April 21, 2020, 11:07 a.m. OK MS C++ 2017 TESTS 24 31 0 1000
77602973 vjudge5 B April 22, 2020, 3:03 a.m. OK MS C++ 2017 TESTS 24 31 0 1000
77630329 little_lion B April 22, 2020, 9:53 a.m. OK MS C++ 2017 TESTS 24 31 0 1000
76695426 Harolinch B April 14, 2020, 1:09 p.m. OK Node.js TESTS 24 171 1024000 1000
76794210 mm944 B April 15, 2020, 12:34 p.m. OK PascalABC.NET TESTS 24 311 614400 1000
76729837 mayakin B April 14, 2020, 6:47 p.m. OK PHP TESTS 24 46 409600 1000
76774614 astrom.lars B April 15, 2020, 8:30 a.m. OK PyPy 2 TESTS 24 124 204800 1000
76793885 YESMAths B April 15, 2020, 12:30 p.m. OK PyPy 2 TESTS 24 139 716800 1000
77281521 yumtam B April 19, 2020, 1:57 p.m. OK PyPy 2 TESTS 24 140 0 1000
76657077 bazzyadb B April 14, 2020, 4:32 a.m. OK PyPy 2 TESTS 24 140 1433600 1000
76791898 distinctlyaverage B April 15, 2020, noon OK PyPy 2 TESTS 24 249 9113600 1000
76708758 shehebe B April 14, 2020, 3:12 p.m. OK PyPy 2 TESTS 24 327 8499200 1000
76722281 jshreyash B April 14, 2020, 5:27 p.m. OK PyPy 3 TESTS 24 140 0 1000
77466260 klkvr B April 21, 2020, 12:30 p.m. OK PyPy 3 TESTS 24 140 0 1000
77464837 shashadwivedi321 B April 21, 2020, 12:16 p.m. OK PyPy 3 TESTS 24 140 0 1000
77194514 indigo153 B April 18, 2020, 2:39 p.m. OK PyPy 3 TESTS 24 140 0 1000
77165811 _Helix_ B April 18, 2020, 9:42 a.m. OK PyPy 3 TESTS 24 140 0 1000
77051285 ProNewbie B April 17, 2020, 8:34 a.m. OK PyPy 3 TESTS 24 140 0 1000
77051260 J01435K B April 17, 2020, 8:33 a.m. OK PyPy 3 TESTS 24 140 0 1000
77031624 vermapri B April 17, 2020, 3:35 a.m. OK PyPy 3 TESTS 24 140 0 1000
76936222 UTMoonlight B April 16, 2020, 6:35 a.m. OK PyPy 3 TESTS 24 140 0 1000
76783430 Shubhanshuj22 B April 15, 2020, 10:02 a.m. OK PyPy 3 TESTS 24 140 0 1000
77247095 hieudaongoc B April 19, 2020, 6:48 a.m. OK Python 2 TESTS 24 171 0 1000
77244535 diwakar123 B April 19, 2020, 6:13 a.m. OK Python 3 TESTS 24 93 0 1000
76761664 auchitya B April 15, 2020, 5:59 a.m. OK Python 3 TESTS 24 93 0 1000
76696548 anumolu_sriharsha B April 14, 2020, 1:19 p.m. OK Python 3 TESTS 24 93 0 1000
76695067 kininge007 B April 14, 2020, 1:06 p.m. OK Python 3 TESTS 24 93 0 1000
76685485 chints11 B April 14, 2020, 11:34 a.m. OK Python 3 TESTS 24 93 0 1000
76668071 sidb99 B April 14, 2020, 8:26 a.m. OK Python 3 TESTS 24 93 0 1000
76787848 visha1 B April 15, 2020, 11:01 a.m. OK Python 3 TESTS 24 93 102400 1000
77314716 geez437 B April 19, 2020, 10:01 p.m. OK Python 3 TESTS 24 93 307200 1000
77039968 vjudge2 B April 17, 2020, 6:11 a.m. OK Python 3 TESTS 24 93 307200 1000
76754625 dinoos B April 15, 2020, 3:53 a.m. OK Python 3 TESTS 24 93 307200 1000
77419455 CPX99 B April 21, 2020, 1:33 a.m. OK Ruby TESTS 24 46 204800 1000
77625791 eugene.l B April 22, 2020, 9:01 a.m. OK Ruby TESTS 24 77 102400 1000
76647937 Verjok B April 14, 2020, 1:15 a.m. OK Ruby TESTS 24 93 0 1000
77385357 fatemender B April 20, 2020, 4:50 p.m. OK Rust TESTS 24 31 0 1000
77179174 manta1130 B April 18, 2020, 12:07 p.m. OK Rust TESTS 24 31 0 1000
76652131 sansen B April 14, 2020, 3:03 a.m. OK Rust TESTS 24 31 0 1000
76673881 bufistov B April 14, 2020, 9:36 a.m. OK Scala TESTS 24 468 0 1000
76923801 yudedako B April 16, 2020, 3:37 a.m. OK Scala TESTS 24 530 512000 1000

remove filters

Back to search problems