Codeforces Round 514 (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
1059 Codeforces Round 514 (Div. 2) FINISHED False 7200 193073099 Oct. 5, 2018, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 7169 ) C Sequence Transformation PROGRAMMING constructive algorithms math 1500

B"Let's call the following process a transformation of a sequence of length n . If the sequence is empty, the process ends. Otherwise, append the greatest common divisor (GCD) of all the elements of the sequence to the result and remove one arbitrary element from the sequence. Thus, when the process ends, we have a sequence of n integers: the greatest common divisors of all the elements in the sequence before each deletion. You are given an integer sequence 1, 2, ... , n . Find the lexicographically maximum result of its transformation. A sequence a_1, a_2, ldots, a_n is lexicographically larger than a sequence b_1, b_2, ldots, b_n , if there is an index i such that a_j = b_j for all j < i , and a_i > b_i . The first and only line of input contains one integer n ( 1 <= n <= 10^6 ). Output n integers -- the lexicographically maximum result of the transformation. In the first sample the answer may be achieved this way: We get the sequence [1, 1, 3] as the result. "...

Tutorials

Codeforces Round #514 (Div. 2) Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
50670824 JoneySun C March 2, 2019, 6:53 a.m. OK Clang++17 Diagnostics TESTS 31 327 0 1500
50672497 JoneySun C March 2, 2019, 7:44 a.m. OK Clang++17 Diagnostics TESTS 31 327 0 1500
45567417 nanae1914 C Nov. 11, 2018, 3:26 p.m. OK D TESTS 31 140 4198400 1500
45545515 ia7ck C Nov. 10, 2018, 11:54 p.m. OK D TESTS 31 155 4198400 1500
44033739 rr_ C Oct. 9, 2018, 12:03 p.m. OK D TESTS 31 171 4198400 1500
55964657 LaSWeeG C June 23, 2019, 11:25 a.m. OK Delphi TESTS 31 108 0 1500
44362010 in123 C Oct. 15, 2018, 2:59 p.m. OK FPC TESTS 31 108 4608000 1500
43923318 vdanh7277 C Oct. 7, 2018, 2:42 a.m. OK FPC TESTS 31 342 4608000 1500
43857652 Ulanov_Victor C Oct. 5, 2018, 4:16 p.m. OK FPC TESTS 31 343 4608000 1500
43861002 PAG C Oct. 5, 2018, 4:31 p.m. OK FPC TESTS 31 1419 0 1500
43865279 TShT C Oct. 5, 2018, 5:51 p.m. OK FPC TESTS 31 1419 0 1500
43865560 TShT C Oct. 5, 2018, 5:56 p.m. OK FPC TESTS 31 1466 0 1500
43923271 vdanh7277 C Oct. 7, 2018, 2:39 a.m. OK FPC TESTS 31 1497 0 1500
44028735 Khanh_Moriaty C Oct. 9, 2018, 9:26 a.m. OK FPC TESTS 31 1497 3993600 1500
43854134 AHTOH._. C Oct. 5, 2018, 3:58 p.m. OK FPC TESTS 31 1512 0 1500
43865262 TShT C Oct. 5, 2018, 5:51 p.m. OK FPC TESTS 31 1575 0 1500
47500832 sansen C Dec. 25, 2018, 5:48 p.m. OK GNU C11 TESTS 31 46 0 1500
43849992 AArtur C Oct. 5, 2018, 3:37 p.m. OK GNU C11 TESTS 31 140 2048000 1500
45140750 luogu_bot5 C Oct. 31, 2018, 2:24 p.m. OK GNU C++11 TESTS 31 31 0 1500
44938573 prayerhgq C Oct. 27, 2018, 6:43 a.m. OK GNU C++11 TESTS 31 31 0 1500
44378876 Umi C Oct. 16, 2018, 1:07 a.m. OK GNU C++11 TESTS 31 31 0 1500
43886606 luogu_bot3 C Oct. 6, 2018, 7:46 a.m. OK GNU C++11 TESTS 31 31 0 1500
43855556 Rising_Date C Oct. 5, 2018, 4:06 p.m. OK GNU C++11 TESTS 31 31 0 1500
43855347 _Silence C Oct. 5, 2018, 4:05 p.m. OK GNU C++11 TESTS 31 31 0 1500
43851615 ultoxtung C Oct. 5, 2018, 3:45 p.m. OK GNU C++11 TESTS 31 31 0 1500
43851554 ygy C Oct. 5, 2018, 3:45 p.m. OK GNU C++11 TESTS 31 31 0 1500
45241542 yc_wang2002 C Nov. 3, 2018, 11:51 a.m. OK GNU C++11 TESTS 31 31 0 1500
52141881 Scut82 C April 1, 2019, 7:15 a.m. OK GNU C++11 TESTS 31 31 0 1500
43858250 ctuu C Oct. 5, 2018, 4:19 p.m. OK GNU C++14 TESTS 31 46 4198400 1500
43853510 ivan.tudor C Oct. 5, 2018, 3:55 p.m. OK GNU C++14 TESTS 31 46 13926400 1500
45310039 vjudge4 C Nov. 5, 2018, 2:58 a.m. OK GNU C++14 TESTS 31 61 0 1500
47296580 vjudge5 C Dec. 20, 2018, 12:16 p.m. OK GNU C++14 TESTS 31 61 0 1500
44357861 nnbszxx C Oct. 15, 2018, 1:15 p.m. OK GNU C++14 TESTS 31 62 0 1500
46056872 vjudge2 C Nov. 22, 2018, 11:24 a.m. OK GNU C++14 TESTS 31 62 0 1500
43947525 Kayo C Oct. 7, 2018, 2:28 p.m. OK GNU C++14 TESTS 31 62 0 1500
55238070 sachin208 C June 7, 2019, 9:25 a.m. OK GNU C++14 TESTS 31 77 0 1500
67765358 dh_love_fzw C Dec. 28, 2019, 3:17 a.m. OK GNU C++14 TESTS 31 77 0 1500
55707450 biliwang C June 18, 2019, 8:23 a.m. OK GNU C++14 TESTS 31 77 0 1500
44751303 ReaLNero1 C Oct. 23, 2018, 8:04 p.m. OK GNU C++17 TESTS 31 31 307200 1500
47296775 vjudge2 C Dec. 20, 2018, 12:21 p.m. OK GNU C++17 TESTS 31 62 0 1500
44054575 brdy C Oct. 9, 2018, 10:02 p.m. OK GNU C++17 TESTS 31 62 7987200 1500
56003617 arbitrary_A C June 24, 2019, 2:18 p.m. OK GNU C++17 TESTS 31 77 0 1500
54492455 valerikk C May 22, 2019, 4:04 p.m. OK GNU C++17 TESTS 31 77 0 1500
52435562 brute_forceCE C April 7, 2019, 3:08 a.m. OK GNU C++17 TESTS 31 77 0 1500
51482343 AliShahali1382 C March 19, 2019, 12:07 p.m. OK GNU C++17 TESTS 31 77 0 1500
51238982 Jonathan_Livingston C March 12, 2019, 8:14 p.m. OK GNU C++17 TESTS 31 77 0 1500
58504106 3agwa C Aug. 9, 2019, 3:37 p.m. OK GNU C++17 TESTS 31 77 0 1500
69461019 Vinayak_Dhiman C Jan. 24, 2020, 10:48 a.m. OK GNU C++17 TESTS 31 77 0 1500
47506707 davidguandev C Dec. 26, 2018, 1:27 a.m. OK Go TESTS 31 62 14233600 1500
45156720 rhdmstjr C Nov. 1, 2018, 3:33 a.m. OK Go TESTS 31 124 4505600 1500
43877004 Haar C Oct. 6, 2018, 2:34 a.m. OK Haskell TESTS 31 109 10649600 1500
44261142 Jarik C Oct. 13, 2018, 2:32 p.m. OK Java 8 TESTS 31 109 0 1500
46094885 SpargelTarzan C Nov. 22, 2018, 10:32 p.m. OK Java 8 TESTS 31 124 3481600 1500
54833614 hridaygoyal007 C May 30, 2019, 9:59 a.m. OK Java 8 TESTS 31 139 3481600 1500
44051287 RestlessAnchoret C Oct. 9, 2018, 7:18 p.m. OK Java 8 TESTS 31 140 3481600 1500
43918734 altik_nik C Oct. 6, 2018, 8:45 p.m. OK Java 8 TESTS 31 155 3481600 1500
56865366 elkadymohammed01 C July 12, 2019, 2:42 a.m. OK Java 8 TESTS 31 155 3584000 1500
63883380 goyalnikhil064 C Oct. 30, 2019, 10:35 p.m. OK Java 8 TESTS 31 155 3993600 1500
44338827 Gleb_Dubosarskii C Oct. 15, 2018, 12:58 a.m. OK Java 8 TESTS 31 155 4096000 1500
44177044 utkarshchawla C Oct. 12, 2018, 9:22 a.m. OK Java 8 TESTS 31 155 8294400 1500
44152525 uc11 C Oct. 11, 2018, 5:03 p.m. OK Java 8 TESTS 31 155 8294400 1500
45092091 nordiccat C Oct. 30, 2018, 10:03 a.m. OK Kotlin TESTS 31 139 5120000 1500
59562659 SYury C Aug. 27, 2019, 9:17 a.m. OK Kotlin TESTS 31 218 11571200 1500
43940946 raynald C Oct. 7, 2018, 11:25 a.m. OK Kotlin TESTS 31 264 11776000 1500
43865134 witchu C Oct. 5, 2018, 5:49 p.m. OK Mono C# TESTS 31 93 10035200 1500
56000950 og.kostya C June 24, 2019, 12:58 p.m. OK Mono C# TESTS 31 124 3174400 1500
43847796 Zvigintsev C Oct. 5, 2018, 3:27 p.m. OK Mono C# TESTS 31 155 13107200 1500
43851688 omikad C Oct. 5, 2018, 3:45 p.m. OK Mono C# TESTS 31 155 14438400 1500
51941562 nemars C March 28, 2019, 2:42 p.m. OK Mono C# TESTS 31 170 14438400 1500
44079583 greenkirill C Oct. 10, 2018, 2:28 p.m. OK Mono C# TESTS 31 171 16384000 1500
43983503 tattosha_aptan C Oct. 8, 2018, 5:18 a.m. OK Mono C# TESTS 31 171 23961600 1500
44688128 fr0st C Oct. 22, 2018, 10:44 a.m. OK Mono C# TESTS 31 171 47513600 1500
43854012 eki C Oct. 5, 2018, 3:58 p.m. OK Mono C# TESTS 31 202 7065600 1500
67608563 hibatibati C Dec. 25, 2019, 2:29 p.m. OK Mono C# TESTS 31 202 23961600 1500
44288469 Houbunsha C Oct. 14, 2018, 8:41 a.m. OK MS C++ TESTS 31 124 0 1500
50640267 powerkeke C March 1, 2019, 1:38 p.m. OK MS C++ TESTS 31 124 0 1500
45670002 vjudge3 C Nov. 13, 2018, 9:59 a.m. OK MS C++ TESTS 31 124 307200 1500
50640290 vjudge1 C March 1, 2019, 1:39 p.m. OK MS C++ TESTS 31 139 0 1500
57016983 vjudge5 C July 14, 2019, 12:06 p.m. OK MS C++ TESTS 31 139 0 1500
50635510 vjudge3 C March 1, 2019, 11:36 a.m. OK MS C++ TESTS 31 139 0 1500
50633538 vjudge5 C March 1, 2019, 10:33 a.m. OK MS C++ TESTS 31 139 0 1500
50636293 vjudge5 C March 1, 2019, 11:57 a.m. OK MS C++ TESTS 31 139 0 1500
50639928 powerkeke C March 1, 2019, 1:29 p.m. OK MS C++ TESTS 31 139 0 1500
50640156 powerkeke C March 1, 2019, 1:35 p.m. OK MS C++ TESTS 31 139 0 1500
69289632 VagrantAC C Jan. 22, 2020, 9:41 a.m. OK MS C++ 2017 TESTS 31 171 0 1500
61458126 vjudge1 C Sept. 29, 2019, 7:19 a.m. OK MS C++ 2017 TESTS 31 187 0 1500
43907999 Fardale C Oct. 6, 2018, 2:53 p.m. OK Ocaml TESTS 31 218 7372800 1500
43851695 sk0 C Oct. 5, 2018, 3:45 p.m. OK Ocaml TESTS 31 280 614400 1500
67403552 aaa_bbb_ccc C Dec. 22, 2019, 5:19 a.m. OK PyPy 2 TESTS 31 171 31436800 1500
49887240 MathisHammel C Feb. 13, 2019, 10:55 p.m. OK PyPy 2 TESTS 31 186 6963200 1500
53438955 musayime C April 27, 2019, 9:21 p.m. OK PyPy 2 TESTS 31 187 33484800 1500
60688125 anshuman16423 C Sept. 16, 2019, 4:13 p.m. OK PyPy 2 TESTS 31 202 30720000 1500
43981545 nealzane C Oct. 8, 2018, 3:32 a.m. OK PyPy 2 TESTS 31 248 33689600 1500
43851158 pa.n.ik C Oct. 5, 2018, 3:43 p.m. OK PyPy 2 TESTS 31 312 25702400 1500
43847581 c1729 C Oct. 5, 2018, 3:26 p.m. OK PyPy 2 TESTS 31 326 58572800 1500
43852403 Pratik_2106 C Oct. 5, 2018, 3:49 p.m. OK PyPy 2 TESTS 31 343 59289600 1500
43854364 vinuthegr8 C Oct. 5, 2018, 4 p.m. OK PyPy 2 TESTS 31 374 59289600 1500
57519325 X_ILYA_X C July 22, 2019, 2:50 p.m. OK PyPy 3 TESTS 31 233 6963200 1500
62214048 UTMoonlight C Oct. 9, 2019, 3:25 p.m. OK PyPy 3 TESTS 31 233 7065600 1500
44014678 111vad111 C Oct. 8, 2018, 8:08 p.m. OK PyPy 3 TESTS 31 265 7782400 1500
43851935 kisa_is_bdsm C Oct. 5, 2018, 3:47 p.m. OK PyPy 3 TESTS 31 280 7782400 1500
43861021 LordVader C Oct. 5, 2018, 4:31 p.m. OK PyPy 3 TESTS 31 420 8294400 1500
61945726 irza_law C Oct. 5, 2019, 10:53 p.m. OK PyPy 3 TESTS 31 421 64512000 1500
43936239 kgcurry59 C Oct. 7, 2018, 9:03 a.m. OK PyPy 3 TESTS 31 436 44544000 1500
52672352 bupt.wc C April 13, 2019, 8:05 a.m. OK PyPy 3 TESTS 31 451 65536000 1500
43912348 PiscesDream C Oct. 6, 2018, 4:50 p.m. OK PyPy 3 TESTS 31 467 63692800 1500
43909427 PiscesDream C Oct. 6, 2018, 3:29 p.m. OK PyPy 3 TESTS 31 467 63692800 1500
43846210 nwi C Oct. 5, 2018, 3:20 p.m. OK Python 2 TESTS 31 296 12185600 1500
43994911 SoSooding C Oct. 8, 2018, 11:01 a.m. OK Python 2 TESTS 31 358 10137600 1500
44010216 SerChirag C Oct. 8, 2018, 5:53 p.m. OK Python 2 TESTS 31 389 16691200 1500
44168408 ybbaigo C Oct. 12, 2018, 3:47 a.m. OK Python 2 TESTS 31 483 13312000 1500
59948950 soumyasarkar1998 C Sept. 3, 2019, 1:53 p.m. OK Python 2 TESTS 31 498 8704000 1500
45851346 EoinDavey C Nov. 16, 2018, 11:44 p.m. OK Python 2 TESTS 31 530 18432000 1500
43856013 recurze C Oct. 5, 2018, 4:08 p.m. OK Python 2 TESTS 31 545 0 1500
43906573 mihir_94 C Oct. 6, 2018, 2:19 p.m. OK Python 2 TESTS 31 576 9318400 1500
44077418 HeypaBHoBeceH C Oct. 10, 2018, 1:36 p.m. OK Python 2 TESTS 31 624 18432000 1500
43854366 ashashwat C Oct. 5, 2018, 4 p.m. OK Python 2 TESTS 31 624 26624000 1500
44424293 wangzpeng C Oct. 17, 2018, 2:49 a.m. OK Python 3 TESTS 31 109 1945600 1500
44751180 dlh C Oct. 23, 2018, 8:01 p.m. OK Python 3 TESTS 31 124 1945600 1500
43905862 hop-hop C Oct. 6, 2018, 2:04 p.m. OK Python 3 TESTS 31 124 1945600 1500
43867922 Z8N C Oct. 5, 2018, 6:55 p.m. OK Python 3 TESTS 31 124 1945600 1500
43865835 DimaBoichuck C Oct. 5, 2018, 6:02 p.m. OK Python 3 TESTS 31 124 1945600 1500
43859353 brenscrazy C Oct. 5, 2018, 4:25 p.m. OK Python 3 TESTS 31 124 1945600 1500
43857858 Bamal C Oct. 5, 2018, 4:17 p.m. OK Python 3 TESTS 31 124 1945600 1500
54019338 as_couple C May 12, 2019, 8:43 a.m. OK Python 3 TESTS 31 124 2048000 1500
43854876 Code__Addict C Oct. 5, 2018, 4:02 p.m. OK Python 3 TESTS 31 124 2969600 1500
44445642 tnowakow C Oct. 17, 2018, 1:49 p.m. OK Python 3 TESTS 31 124 4505600 1500
43857700 koikotya C Oct. 5, 2018, 4:16 p.m. OK Ruby TESTS 31 405 18227200 1500
43856104 AnandVeeramani C Oct. 5, 2018, 4:09 p.m. OK Ruby TESTS 31 764 27033600 1500
43861578 geckods C Oct. 5, 2018, 4:33 p.m. OK Ruby TESTS 31 967 0 1500
43944107 Felerius C Oct. 7, 2018, 12:52 p.m. OK Rust TESTS 31 233 0 1500
43917182 clrcldy C Oct. 6, 2018, 7:34 p.m. OK Rust TESTS 31 233 6041600 1500
43922148 llllllll C Oct. 7, 2018, 1:21 a.m. OK Rust TESTS 31 234 0 1500
43875318 DragoonKiller C Oct. 6, 2018, 1:10 a.m. OK Rust TESTS 31 295 9420800 1500
44000865 yakamoto C Oct. 8, 2018, 1:39 p.m. OK Scala TESTS 31 608 11673600 1500

remove filters

Back to search problems