Codeforces Round 744 (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
1579 Codeforces Round 744 (Div. 3) FINISHED False 8100 98983499 Sept. 28, 2021, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 21807 ) E1 Permutation Minimization by Deque PROGRAMMING constructive algorithms greedy math

B'In fact, the problems E1 and E2 do not have much in common. You should probably think of them as two separate problems. A permutation p of size n is given. A permutation of size n is an array of size n in which each integer from 1 to n occurs exactly once. For example, [1, 4, 3, 2] and [4, 2, 1, 3] are correct permutations while [1, 2, 4] and [1, 2, 2] are not. Let us consider an empty deque (double-ended queue). A deque is a data structure that supports adding elements to both the beginning and the end. So, if there are elements [1, 5, 2] currently in the deque, adding an element 4 to the beginning will produce the sequence [ color{red}{4}, 1, 5, 2] , and adding same element to the end will produce [1, 5, 2, color{red}{4}] . The elements of the permutation are sequentially added to the initially empty deque, starting with p_1 and finishing with p_n . Before adding each element to the deque, you may choose whether to add it to the beginning or the end. For example, if we consider a permutation p = [3, 1, 2, 4] , one of the possible sequences of actions looks like this: quad 1.add 3 to the end of the deque:deque has a sequence [ color{red}{3}] in it; quad 2.add 1 to the beginning of the deque:deque has a sequence [ color{red}{1}, 3] in it; quad 3.add 2 to the end of the deque:deque has a sequence [1, 3, color{red}{2}] in it; quad 4.add 4 to the end of the deque:deque has a sequence [1, 3, 2, color{red}{4}] in it; Find the lexicographically smallest possible sequence of elements in the deque after the entire permutation has been processed. A sequence [x_1, x_2, ldots, x_n] is lexicographically smaller than the sequence [y_1, y_2, ldots, y_n] if there exists such i <= q n that x_1 = y_1 , x_2 = y_2 , ldots , x_{i - 1} = y_{i - 1} and x_i < y_i'...

Tutorials

Codeforces Round #744 (Div. 3) Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
130253130 tazrian_tahlil E1 Sept. 29, 2021, 10:33 a.m. OK GNU C11 TESTS 25 764 5324800
130276217 aalhadk E1 Sept. 29, 2021, 2:35 p.m. OK GNU C11 TESTS 25 779 6041600
130251144 shubh2 E1 Sept. 29, 2021, 10:08 a.m. OK GNU C11 TESTS 25 810 6041600
130251649 sheru_codes E1 Sept. 29, 2021, 10:15 a.m. OK GNU C++14 TESTS 25 62 4812800
130222443 Teja_The_Pahadi_Boy E1 Sept. 29, 2021, 3:09 a.m. OK GNU C++14 TESTS 25 62 6348800
130261932 adarsh_verma_ E1 Sept. 29, 2021, 12:12 p.m. OK GNU C++14 TESTS 25 77 3993600
130262138 bxdebb E1 Sept. 29, 2021, 12:15 p.m. OK GNU C++14 TESTS 25 77 4608000
130318671 plastical E1 Sept. 30, 2021, 5:15 a.m. OK GNU C++14 TESTS 25 77 4812800
130273403 arpit.mittal E1 Sept. 29, 2021, 2:07 p.m. OK GNU C++14 TESTS 25 77 4812800
130269396 Tanim E1 Sept. 29, 2021, 1:29 p.m. OK GNU C++14 TESTS 25 77 4812800
130268895 anton_h E1 Sept. 29, 2021, 1:24 p.m. OK GNU C++14 TESTS 25 77 4812800
130320970 SayuOgiwara E1 Sept. 30, 2021, 5:57 a.m. OK GNU C++14 TESTS 25 77 4812800
130253758 tk-7 E1 Sept. 29, 2021, 10:40 a.m. OK GNU C++14 TESTS 25 77 4812800
130251203 shano123 E1 Sept. 29, 2021, 10:09 a.m. OK GNU C++17 TESTS 25 62 4812800
130262584 Namazabi12 E1 Sept. 29, 2021, 12:19 p.m. OK GNU C++17 TESTS 25 62 4812800
130265075 zzu_juruo E1 Sept. 29, 2021, 12:46 p.m. OK GNU C++17 TESTS 25 77 4300800
130254441 mobasshirahmad E1 Sept. 29, 2021, 10:49 a.m. OK GNU C++17 TESTS 25 77 4710400
130312808 fneleq E1 Sept. 30, 2021, 3:06 a.m. OK GNU C++17 TESTS 25 77 4812800
130311635 totallynotafakeacc E1 Sept. 30, 2021, 2:36 a.m. OK GNU C++17 TESTS 25 77 4812800
130308427 kongfang89 E1 Sept. 30, 2021, 12:23 a.m. OK GNU C++17 TESTS 25 77 4812800
130301958 sushkov.pv E1 Sept. 29, 2021, 8:38 p.m. OK GNU C++17 TESTS 25 77 4812800
130301102 jporwal09 E1 Sept. 29, 2021, 8:18 p.m. OK GNU C++17 TESTS 25 77 4812800
130299562 trxke01 E1 Sept. 29, 2021, 7:45 p.m. OK GNU C++17 TESTS 25 77 4812800
130254265 timeguy E1 Sept. 29, 2021, 10:47 a.m. OK GNU C++17 (64) TESTS 25 61 5222400
130311046 jainbot27 E1 Sept. 30, 2021, 2:19 a.m. OK GNU C++17 (64) TESTS 25 61 5222400
130288455 sagar_sk007 E1 Sept. 29, 2021, 4:59 p.m. OK GNU C++17 (64) TESTS 25 61 6041600
130311507 nitin_05 E1 Sept. 30, 2021, 2:32 a.m. OK GNU C++17 (64) TESTS 25 62 5222400
130305386 Iftekhar_Hakim_K E1 Sept. 29, 2021, 10:20 p.m. OK GNU C++17 (64) TESTS 25 62 5222400
130299032 Mohamed_5aied E1 Sept. 29, 2021, 7:34 p.m. OK GNU C++17 (64) TESTS 25 62 5222400
130291838 ilia_rr E1 Sept. 29, 2021, 5:44 p.m. OK GNU C++17 (64) TESTS 25 62 5222400
130288186 thomas_li E1 Sept. 29, 2021, 4:55 p.m. OK GNU C++17 (64) TESTS 25 62 5222400
130262824 sanchay_ E1 Sept. 29, 2021, 12:22 p.m. OK GNU C++17 (64) TESTS 25 62 5222400
130313807 over_flow E1 Sept. 30, 2021, 3:29 a.m. OK GNU C++17 (64) TESTS 25 62 5222400
130247314 BamgoeSN E1 Sept. 29, 2021, 9:20 a.m. OK Go TESTS 25 93 16896000
130302381 glebsamsonov E1 Sept. 29, 2021, 8:49 p.m. OK Go TESTS 25 1278 15155200
130303470 ytripathi891 E1 Sept. 29, 2021, 9:19 p.m. OK Java 11 TESTS 25 249 23961600
130267207 bittubittu E1 Sept. 29, 2021, 1:07 p.m. OK Java 11 TESTS 25 280 29184000
130244482 iamsoumik E1 Sept. 29, 2021, 8:46 a.m. OK Java 11 TESTS 25 296 29184000
130226343 SnacksTime E1 Sept. 29, 2021, 4:27 a.m. OK Java 11 TESTS 25 296 35942400
130298737 RadheKrishna1815 E1 Sept. 29, 2021, 7:28 p.m. OK Java 11 TESTS 25 296 36147200
130242184 adityasin9h E1 Sept. 29, 2021, 8:18 a.m. OK Java 11 TESTS 25 311 29184000
130269933 RegalBeast E1 Sept. 29, 2021, 1:34 p.m. OK Java 11 TESTS 25 311 29286400
130245665 Multi-Thread E1 Sept. 29, 2021, 9 a.m. OK Java 11 TESTS 25 311 31027200
130224236 unfixedbug E1 Sept. 29, 2021, 3:46 a.m. OK Java 11 TESTS 25 327 28364800
130293636 Spectra369 E1 Sept. 29, 2021, 6:09 p.m. OK Java 11 TESTS 25 327 33792000
130243032 double-b E1 Sept. 29, 2021, 8:29 a.m. OK Java 8 TESTS 25 171 25600000
130268548 toufique_husein E1 Sept. 29, 2021, 1:20 p.m. OK Java 8 TESTS 25 202 21196800
130223578 flip-flop E1 Sept. 29, 2021, 3:33 a.m. OK Java 8 TESTS 25 217 22016000
130303202 coolManit E1 Sept. 29, 2021, 9:11 p.m. OK Java 8 TESTS 25 217 25702400
130247303 mike1729 E1 Sept. 29, 2021, 9:20 a.m. OK Java 8 TESTS 25 218 26521600
130226986 BruteForcee E1 Sept. 29, 2021, 4:40 a.m. OK Java 8 TESTS 25 233 25702400
130301655 abdo123 E1 Sept. 29, 2021, 8:31 p.m. OK Java 8 TESTS 25 233 33996800
130233565 dheerajchhatanidc E1 Sept. 29, 2021, 6:34 a.m. OK Java 8 TESTS 25 249 28876800
130256908 pgthebigshot E1 Sept. 29, 2021, 11:18 a.m. OK Java 8 TESTS 25 280 29593600
130257762 pgthebigshot E1 Sept. 29, 2021, 11:27 a.m. OK Java 8 TESTS 25 295 29593600
130268653 BIT E1 Sept. 29, 2021, 1:22 p.m. OK Mono C# TESTS 25 1279 37273600
130309661 the-fly0618 E1 Sept. 30, 2021, 1:30 a.m. OK MS C++ 2017 TESTS 25 249 9216000
130243683 russian_proger E1 Sept. 29, 2021, 8:37 a.m. OK MS C++ 2017 TESTS 25 264 5222400
130239985 nor_or E1 Sept. 29, 2021, 7:51 a.m. OK MS C++ 2017 TESTS 25 265 5222400
130243956 russian_proger E1 Sept. 29, 2021, 8:40 a.m. OK MS C++ 2017 TESTS 25 265 5222400
130243920 russian_proger E1 Sept. 29, 2021, 8:39 a.m. OK MS C++ 2017 TESTS 25 265 5222400
130243640 russian_proger E1 Sept. 29, 2021, 8:36 a.m. OK MS C++ 2017 TESTS 25 265 5222400
130243534 russian_proger E1 Sept. 29, 2021, 8:35 a.m. OK MS C++ 2017 TESTS 25 265 5222400
130244447 zeratul_34 E1 Sept. 29, 2021, 8:46 a.m. OK MS C++ 2017 TESTS 25 265 5324800
130251354 Gor_04 E1 Sept. 29, 2021, 10:10 a.m. OK MS C++ 2017 TESTS 25 265 6041600
130292263 kirill2000 E1 Sept. 29, 2021, 5:50 p.m. OK MS C++ 2017 TESTS 25 265 6041600
130235276 tabibi E1 Sept. 29, 2021, 6:54 a.m. OK .NET Core C# TESTS 25 155 38912000
130271828 Sanjit E1 Sept. 29, 2021, 1:52 p.m. OK .NET Core C# TESTS 25 186 47923200
130242289 VN.Kiet E1 Sept. 29, 2021, 8:19 a.m. OK PyPy 3 TESTS 25 171 41062400
130254355 reddevil100 E1 Sept. 29, 2021, 10:48 a.m. OK PyPy 3 TESTS 25 187 39731200
130241081 Melmetal E1 Sept. 29, 2021, 8:04 a.m. OK PyPy 3 TESTS 25 327 40140800
130280129 Girniiiii E1 Sept. 29, 2021, 3:18 p.m. OK PyPy 3 TESTS 25 373 40140800
130303982 someone_elif E1 Sept. 29, 2021, 9:33 p.m. OK PyPy 3 TESTS 25 373 40448000
130259394 cloak E1 Sept. 29, 2021, 11:45 a.m. OK PyPy 3 TESTS 25 374 38502400
130272360 harshgoyal178 E1 Sept. 29, 2021, 1:56 p.m. OK PyPy 3 TESTS 25 374 39321600
130289355 SSCoding123 E1 Sept. 29, 2021, 5:12 p.m. OK PyPy 3 TESTS 25 374 39936000
130281490 phantomxxx E1 Sept. 29, 2021, 3:33 p.m. OK PyPy 3 TESTS 25 374 40038400
130317129 i8nd5t E1 Sept. 30, 2021, 4:45 a.m. OK PyPy 3 TESTS 25 374 41164800
130254339 paradoxxd E1 Sept. 29, 2021, 10:48 a.m. OK Python 3 TESTS 25 248 21606400
130295925 tnowakow E1 Sept. 29, 2021, 6:40 p.m. OK Python 3 TESTS 25 249 22425600
130256390 paradoxxd E1 Sept. 29, 2021, 11:12 a.m. OK Python 3 TESTS 25 295 21811200
130263688 piSquared E1 Sept. 29, 2021, 12:31 p.m. OK Python 3 TESTS 25 373 20377600
130295417 Afsan_Habib E1 Sept. 29, 2021, 6:32 p.m. OK Python 3 TESTS 25 374 20377600
130273862 raavan_2.0 E1 Sept. 29, 2021, 2:11 p.m. OK Python 3 TESTS 25 374 20377600
130228454 Apu123 E1 Sept. 29, 2021, 5:03 a.m. OK Python 3 TESTS 25 374 20377600
130270284 NewHupopo E1 Sept. 29, 2021, 1:38 p.m. OK Python 3 TESTS 25 374 20684800
130311065 190031512_suhana E1 Sept. 30, 2021, 2:20 a.m. OK Python 3 TESTS 25 389 20377600
130287657 sh1194 E1 Sept. 29, 2021, 4:48 p.m. OK Python 3 TESTS 25 389 20377600
130262259 IvanDyachenko E1 Sept. 29, 2021, 12:16 p.m. OK Scala TESTS 25 701 70348800

remove filters

Back to search problems