Technocup 2020 - Elimination Round 1

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
1223 Technocup 2020 - Elimination Round 1 FINISHED False 7200 166978511 Oct. 6, 2019, 3:05 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 4104 ) D Sequence Sorting PROGRAMMING dp greedy two pointers 2000

B'You are given a sequence a_1, a_2, ... , a_n , consisting of integers. You can apply the following operation to this sequence: choose some integer x and move all elements equal to x either to the beginning, or to the end of a . Note that you have to move all these elements in one direction in one operation. For example, if a = [2, 1, 3, 1, 1, 3, 2] , you can get the following sequences in one operation (for convenience, denote elements equal to x as x -elements): You have to determine the minimum number of such operations so that the sequence a becomes sorted in non-descending order. Non-descending order means that for all i from 2 to n , the condition a_{i-1} <= a_i is satisfied. Note that you have to answer q independent queries. The first line contains one integer q ( 1 <= q <= 3 cdot 10^5 ) -- the number of the queries. Each query is represented by two consecutive lines. The first line of each query contains one integer n ( 1 <= n <= 3 cdot 10^5 ) -- the number of elements. The second line of each query contains n integers a_1, a_2, ... , a_n ( 1 <= a_i <= n ) -- the elements. It is guaranteed that the sum of all n does not exceed 3 cdot 10^5 . For each query print one integer -- the minimum number of operation for sorting sequence a in non-descending order. In the first query, you can move all 1 -elements to the beginning (after that sequence turn into [1, 1, 1, 3, 6, 6, 3] ) and then move all 6 -elements to the end. In the second query, the sequence is sorted initially, so the answer is zero. In the third query, you have to move all 2 -elements to the beginning. '...

Tutorials

Сodeforces Round 591 (and Technocup 2020 — Elimination Round 1) Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
64867126 reticent.001 D Nov. 14, 2019, 6:44 a.m. OK GNU C++11 TESTS 40 31 3584000 2000
64863304 yuy D Nov. 14, 2019, 4:38 a.m. OK GNU C++11 TESTS 40 31 3584000 2000
64863719 xgcjay D Nov. 14, 2019, 4:52 a.m. OK GNU C++11 TESTS 40 31 7372800 2000
64864467 wyy2004 D Nov. 14, 2019, 5:20 a.m. OK GNU C++11 TESTS 40 31 24064000 2000
63994981 Dream-chasing_Juvenile D Nov. 1, 2019, 2:20 p.m. OK GNU C++11 TESTS 40 46 3584000 2000
64863499 yugao D Nov. 14, 2019, 4:45 a.m. OK GNU C++11 TESTS 40 46 3686400 2000
64865354 yuzhechuan D Nov. 14, 2019, 5:56 a.m. OK GNU C++11 TESTS 40 46 4812800 2000
62039866 KaiserYang D Oct. 7, 2019, 5:33 a.m. OK GNU C++11 TESTS 39 46 4812800 2000
62095167 BeNoble D Oct. 8, 2019, 7:15 a.m. OK GNU C++11 TESTS 39 46 4915200 2000
62346591 AutumnKite D Oct. 11, 2019, 7:47 a.m. OK GNU C++11 TESTS 40 46 5836800 2000
62177266 dh_love_fzw D Oct. 9, 2019, 4:48 a.m. OK GNU C++14 TESTS 40 109 3584000 2000
62100018 PCCCP D Oct. 8, 2019, 8:49 a.m. OK GNU C++14 TESTS 39 109 7987200 2000
64277938 Lezedary_sandwich D Nov. 4, 2019, 11:04 p.m. OK GNU C++14 TESTS 40 109 11673600 2000
63532698 suzhen D Oct. 27, 2019, 7:11 a.m. OK GNU C++14 TESTS 40 124 3584000 2000
62096953 jack_guo D Oct. 8, 2019, 7:52 a.m. OK GNU C++14 TESTS 39 124 3584000 2000
62096898 jack_guo D Oct. 8, 2019, 7:51 a.m. OK GNU C++14 TESTS 39 124 3584000 2000
62096801 jack_guo D Oct. 8, 2019, 7:49 a.m. OK GNU C++14 TESTS 39 124 3584000 2000
62094459 jr3ed D Oct. 8, 2019, 7 a.m. OK GNU C++14 TESTS 39 124 3584000 2000
64450549 ACtest D Nov. 7, 2019, 6:55 a.m. OK GNU C++14 TESTS 40 124 4812800 2000
62020631 Feechka_ D Oct. 6, 2019, 4:37 p.m. OK GNU C++14 TESTS 39 124 5529600 2000
62009107 KAZINAK_1488 D Oct. 6, 2019, 3:41 p.m. OK GNU C++17 TESTS 39 109 3584000 2000
67480663 vjudge1 D Dec. 23, 2019, 3:51 p.m. OK GNU C++17 TESTS 40 109 6451200 2000
62009604 seiko.iwasawa D Oct. 6, 2019, 3:42 p.m. OK GNU C++17 TESTS 39 109 6451200 2000
64652061 _N0NAME D Nov. 10, 2019, 5:39 p.m. OK GNU C++17 TESTS 40 109 6758400 2000
62167849 MathAlex D Oct. 8, 2019, 9:42 p.m. OK GNU C++17 TESTS 40 124 2355200 2000
62057166 kuksag D Oct. 7, 2019, 12:28 p.m. OK GNU C++17 TESTS 39 124 2355200 2000
62026401 MrFired D Oct. 6, 2019, 8:25 p.m. OK GNU C++17 TESTS 39 124 2355200 2000
62329997 DarkAvengerr D Oct. 10, 2019, 8:12 p.m. OK GNU C++17 TESTS 40 124 3584000 2000
62438272 BlueDiamond D Oct. 12, 2019, 6:18 p.m. OK GNU C++17 TESTS 40 124 3993600 2000
69076985 Doncic D Jan. 19, 2020, 4:02 a.m. OK GNU C++17 TESTS 40 124 4812800 2000
62103532 jmazon D Oct. 8, 2019, 9:57 a.m. OK Haskell TESTS 39 1341 68403200 2000
66525143 tusharjape007 D Dec. 9, 2019, 4:02 a.m. OK Java 11 TESTS 40 811 39014400 2000
62103900 4mda4mda D Oct. 8, 2019, 10:05 a.m. OK Java 8 TESTS 39 187 13312000 2000
62017432 mikhaylov_boris D Oct. 6, 2019, 4:12 p.m. OK Java 8 TESTS 39 202 11366400 2000
62011980 Nutella3000 D Oct. 6, 2019, 3:50 p.m. OK Java 8 TESTS 39 202 13004800 2000
63094238 yaoct D Oct. 21, 2019, 7:46 p.m. OK Java 8 TESTS 40 233 15360000 2000
62063882 real.emerald D Oct. 7, 2019, 2:32 p.m. OK Java 8 TESTS 39 233 24576000 2000
62210048 optimaniax D Oct. 9, 2019, 2:14 p.m. OK Java 8 TESTS 40 343 19456000 2000
62055782 satya26 D Oct. 7, 2019, noon OK Java 8 TESTS 39 358 31948800 2000
62063005 sthfaceless D Oct. 7, 2019, 2:15 p.m. OK Java 8 TESTS 39 390 31129600 2000
62044045 shaurya024 D Oct. 7, 2019, 6:56 a.m. OK Java 8 TESTS 39 685 12492800 2000
62912371 vjudge3 D Oct. 19, 2019, 7:42 a.m. OK MS C++ TESTS 40 109 7270400 2000
66488477 vjudge1 D Dec. 8, 2019, 7:33 a.m. OK MS C++ TESTS 40 1185 15257600 2000
62106891 yoko2001_1 D Oct. 8, 2019, 11:04 a.m. OK MS C++ 2017 TESTS 39 202 8499200 2000
62178709 Ivan11 D Oct. 9, 2019, 5:33 a.m. OK MS C++ 2017 TESTS 40 234 4812800 2000
62022719 GottaGoFaster D Oct. 6, 2019, 5 p.m. OK MS C++ 2017 TESTS 39 436 6041600 2000
62021697 MrLolthe1st D Oct. 6, 2019, 4:49 p.m. OK MS C++ 2017 TESTS 39 920 29491200 2000
63286496 Fyodor D Oct. 24, 2019, 10:31 a.m. OK MS C++ 2017 TESTS 40 1419 8294400 2000
63213402 loochek D Oct. 23, 2019, 5:02 a.m. OK MS C++ 2017 TESTS 40 1450 4300800 2000
62014552 ialakhtin D Oct. 6, 2019, 3:59 p.m. OK MS C++ 2017 TESTS 39 1528 5324800 2000
64702799 DarisHS D Nov. 11, 2019, 3:24 p.m. OK MS C++ 2017 TESTS 40 1528 10342400 2000
62079777 serg3000 D Oct. 7, 2019, 8:04 p.m. OK MS C++ 2017 TESTS 39 1559 16691200 2000
67775811 0cHild8oFF0the8dEvil D Dec. 28, 2019, 8:55 a.m. OK MS C++ 2017 TESTS 40 1560 84992000 2000
63022768 YESMAths D Oct. 20, 2019, 3:10 p.m. OK PyPy 2 TESTS 40 296 34816000 2000
62010717 asvasil D Oct. 6, 2019, 3:46 p.m. OK PyPy 3 TESTS 39 545 25497600 2000
62185459 lyjccmm D Oct. 9, 2019, 8:07 a.m. OK Python 2 TESTS 40 1372 24064000 2000
66672234 sruthi_1729 D Dec. 12, 2019, 9:50 a.m. OK Python 2 TESTS 40 1450 24268800 2000
62037665 Dart-Xeyter D Oct. 7, 2019, 4:37 a.m. OK Python 3 TESTS 39 1887 20480000 2000

remove filters

Back to search problems