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 |
---|---|---|---|---|---|---|
1856 | Codeforces Round 890 (Div. 2) supported by Constructor Institute | FINISHED | False | 7200 | 45933863 | Aug. 5, 2023, 2:35 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 26882 ) | A | Tales of a Sort | PROGRAMMING | binary search implementation |
B'Alphen has an array of positive integers a of length n . Alphen can perform the following operation: Alphen will perform the above operation until a is sorted, that is a satisfies a_1 <= q a_2 <= q ldots <= q a_n . How many operations will Alphen perform? Under the constraints of the problem, it can be proven that Alphen will perform a finite number of operations. Each test contains multiple test cases. The first line of input contains a single integer t ( 1 <= t <= 500 ) -- the number of test cases. The description of the test cases follows. The first line of each test case contains a single integer n ( 2 <= n <= 50 ) -- the length of the array a . The second line of each test case contains n integers a_1, a_2, ... , a_n ( 1 <= a_i <= 10 ^ 9 ) -- the elements of the array a . For each test case, output a single integer -- the number of operations that Alphen will perform. In the first test case, we have a=[1,2,3] . Since a is already sorted, Alphen will not need to perform any operations. So, the answer is 0 . In the second test case, we have a=[2,1,2,1,2] . Since a is not initially sorted, Alphen will perform one operation to make a=[1,0,1,0,1] . After performing one operation, a is still not sorted, so Alphen will perform another operation to make a=[0,0,0,0,0] . Since a is sorted, Alphen will not perform any other operations. Since Alphen has performed two operations in total, the answer is 2 . '... |
Codeforces Round #890 (Div. 2) Editorial |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
217391950 | ministove3yo | A | Aug. 6, 2023, 1:06 a.m. | OK | Clang++20 Diagnostics | TESTS | 5 | 140 | 0 | ||
217389444 | evertedsphere | A | Aug. 5, 2023, 11:58 p.m. | OK | Clang++20 Diagnostics | TESTS | 5 | 140 | 7372800 | ||
217397849 | 495684945 | A | Aug. 6, 2023, 2:57 a.m. | OK | Clang++20 Diagnostics | TESTS | 5 | 155 | 0 | ||
217399397 | Aniket_1907 | A | Aug. 6, 2023, 3:24 a.m. | OK | Clang++20 Diagnostics | TESTS | 5 | 155 | 0 | ||
217360942 | adil7 | A | Aug. 5, 2023, 5:50 p.m. | OK | Clang++20 Diagnostics | TESTS | 5 | 171 | 0 | ||
217396292 | coder_yash_rudra_248 | A | Aug. 6, 2023, 2:30 a.m. | OK | Clang++20 Diagnostics | TESTS | 5 | 217 | 4198400 | ||
217377136 | Nuhash1 | A | Aug. 5, 2023, 8:11 p.m. | OK | GNU C11 | TESTS | 5 | 15 | 0 | ||
217380558 | coderiser404 | A | Aug. 5, 2023, 8:55 p.m. | OK | GNU C11 | TESTS | 5 | 15 | 0 | ||
217374191 | Fadeevich | A | Aug. 5, 2023, 7:42 p.m. | OK | GNU C11 | TESTS | 5 | 15 | 102400 | ||
217373470 | Mysterious_Queen | A | Aug. 5, 2023, 7:34 p.m. | OK | GNU C11 | TESTS | 5 | 31 | 0 | ||
217394880 | quanquan | A | Aug. 6, 2023, 2:05 a.m. | OK | GNU C++14 | TESTS | 5 | 0 | 0 | ||
217406993 | raj_rajeev | A | Aug. 6, 2023, 5:22 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | ||
217406648 | xxzxsyl | A | Aug. 6, 2023, 5:18 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | ||
217402469 | zhangzhimo | A | Aug. 6, 2023, 4:14 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | ||
217400933 | MalayZ | A | Aug. 6, 2023, 3:49 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | ||
217399277 | 3Nic33K | A | Aug. 6, 2023, 3:22 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | ||
217406996 | 5-3 | A | Aug. 6, 2023, 5:22 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | ||
217407342 | halehu | A | Aug. 6, 2023, 5:27 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | ||
217409641 | LeoChan2022 | A | Aug. 6, 2023, 5:54 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | ||
217407261 | pzj114514 | A | Aug. 6, 2023, 5:26 a.m. | OK | GNU C++14 | TESTS | 5 | 15 | 0 | ||
217356467 | faridasaid | A | Aug. 5, 2023, 5:25 p.m. | OK | GNU C++17 | TESTS | 5 | 0 | 102400 | ||
217363264 | KI-RA | A | Aug. 5, 2023, 6:06 p.m. | OK | GNU C++17 | TESTS | 5 | 0 | 102400 | ||
217359693 | debosmita1919 | A | Aug. 5, 2023, 5:42 p.m. | OK | GNU C++17 | TESTS | 5 | 0 | 102400 | ||
217406903 | DK_003 | A | Aug. 6, 2023, 5:21 a.m. | OK | GNU C++17 | TESTS | 5 | 15 | 0 | ||
217406357 | Shahreyaar | A | Aug. 6, 2023, 5:14 a.m. | OK | GNU C++17 | TESTS | 5 | 15 | 0 | ||
217406136 | r-a-j | A | Aug. 6, 2023, 5:10 a.m. | OK | GNU C++17 | TESTS | 5 | 15 | 0 | ||
217408548 | Suraj_siya | A | Aug. 6, 2023, 5:42 a.m. | OK | GNU C++17 | TESTS | 5 | 15 | 0 | ||
217407197 | anne12503 | A | Aug. 6, 2023, 5:25 a.m. | OK | GNU C++17 | TESTS | 5 | 15 | 0 | ||
217406987 | Abhishek_821023 | A | Aug. 6, 2023, 5:22 a.m. | OK | GNU C++17 | TESTS | 5 | 15 | 0 | ||
217407747 | _MostaFiz | A | Aug. 6, 2023, 5:32 a.m. | OK | GNU C++17 | TESTS | 5 | 15 | 0 | ||
217385308 | HavlongRG | A | Aug. 5, 2023, 10:18 p.m. | OK | GNU C++17 (64) | TESTS | 5 | 0 | 0 | ||
217403699 | ArsNova | A | Aug. 6, 2023, 4:34 a.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | ||
217407846 | luogu_bot2 | A | Aug. 6, 2023, 5:33 a.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | ||
217406537 | Samiul2651 | A | Aug. 6, 2023, 5:16 a.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | ||
217404445 | aarindamm | A | Aug. 6, 2023, 4:46 a.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | ||
217396916 | sandipondas25 | A | Aug. 6, 2023, 2:40 a.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | ||
217396867 | Hytidel | A | Aug. 6, 2023, 2:40 a.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | ||
217396209 | b_i_b | A | Aug. 6, 2023, 2:28 a.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | ||
217395569 | SoiMae | A | Aug. 6, 2023, 2:18 a.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | ||
217394487 | A_S_T | A | Aug. 6, 2023, 1:58 a.m. | OK | GNU C++17 (64) | TESTS | 5 | 15 | 0 | ||
217406051 | a.s.i.coder | A | Aug. 6, 2023, 5:09 a.m. | OK | GNU C++20 (64) | TESTS | 5 | 0 | 0 | ||
217403901 | nerdykafka | A | Aug. 6, 2023, 4:37 a.m. | OK | GNU C++20 (64) | TESTS | 5 | 0 | 0 | ||
217403465 | amaN07 | A | Aug. 6, 2023, 4:30 a.m. | OK | GNU C++20 (64) | TESTS | 5 | 0 | 0 | ||
217403248 | hnust_wanjiawen | A | Aug. 6, 2023, 4:27 a.m. | OK | GNU C++20 (64) | TESTS | 5 | 0 | 0 | ||
217402594 | Tethet | A | Aug. 6, 2023, 4:16 a.m. | OK | GNU C++20 (64) | TESTS | 5 | 0 | 0 | ||
217402580 | ehdxbc | A | Aug. 6, 2023, 4:16 a.m. | OK | GNU C++20 (64) | TESTS | 5 | 0 | 0 | ||
217406145 | infigeek | A | Aug. 6, 2023, 5:11 a.m. | OK | GNU C++20 (64) | TESTS | 5 | 0 | 0 | ||
217406317 | Binary_luver | A | Aug. 6, 2023, 5:13 a.m. | OK | GNU C++20 (64) | TESTS | 5 | 0 | 0 | ||
217408485 | rescue_me | A | Aug. 6, 2023, 5:42 a.m. | OK | GNU C++20 (64) | TESTS | 5 | 0 | 0 | ||
217409750 | Pratyogi_7 | A | Aug. 6, 2023, 5:56 a.m. | OK | GNU C++20 (64) | TESTS | 5 | 0 | 0 | ||
217408694 | katomasao | A | Aug. 6, 2023, 5:44 a.m. | OK | Haskell | TESTS | 5 | 30 | 0 | ||
217364931 | prabhjout | A | Aug. 5, 2023, 6:19 p.m. | OK | Java 11 | TESTS | 5 | 187 | 0 | ||
217357827 | S8UL_1963 | A | Aug. 5, 2023, 5:31 p.m. | OK | Java 11 | TESTS | 5 | 187 | 0 | ||
217356297 | ujjwal_a0001 | A | Aug. 5, 2023, 5:25 p.m. | OK | Java 11 | TESTS | 5 | 187 | 0 | ||
217410114 | GRVkmr | A | Aug. 6, 2023, 6 a.m. | OK | Java 11 | TESTS | 5 | 233 | 0 | ||
217405712 | manish26eleven | A | Aug. 6, 2023, 5:04 a.m. | OK | Java 11 | TESTS | 5 | 233 | 0 | ||
217396330 | archieagarwal | A | Aug. 6, 2023, 2:31 a.m. | OK | Java 11 | TESTS | 5 | 233 | 0 | ||
217363531 | vishesh9096 | A | Aug. 5, 2023, 6:08 p.m. | OK | Java 11 | TESTS | 5 | 233 | 0 | ||
217363007 | satabdigoswami87 | A | Aug. 5, 2023, 6:04 p.m. | OK | Java 11 | TESTS | 5 | 233 | 0 | ||
217361119 | verma.shivam2605 | A | Aug. 5, 2023, 5:51 p.m. | OK | Java 11 | TESTS | 5 | 233 | 0 | ||
217359190 | mschact | A | Aug. 5, 2023, 5:39 p.m. | OK | Java 11 | TESTS | 5 | 233 | 0 | ||
217372576 | shashankp10 | A | Aug. 5, 2023, 7:25 p.m. | OK | Java 17 | TESTS | 5 | 155 | 102400 | ||
217407245 | rdhakar246 | A | Aug. 6, 2023, 5:26 a.m. | OK | Java 17 | TESTS | 5 | 171 | 0 | ||
217400653 | Prime369 | A | Aug. 6, 2023, 3:44 a.m. | OK | Java 17 | TESTS | 5 | 186 | 512000 | ||
217385923 | mangos194 | A | Aug. 5, 2023, 10:33 p.m. | OK | Java 17 | TESTS | 5 | 187 | 0 | ||
217404257 | fightingxjz | A | Aug. 6, 2023, 4:43 a.m. | OK | Java 17 | TESTS | 5 | 202 | 0 | ||
217388719 | woodyiiiiiii | A | Aug. 5, 2023, 11:39 p.m. | OK | Java 17 | TESTS | 5 | 202 | 614400 | ||
217377134 | aryangupta1604 | A | Aug. 5, 2023, 8:11 p.m. | OK | Java 17 | TESTS | 5 | 218 | 409600 | ||
217381550 | imvivekthakur | A | Aug. 5, 2023, 9:12 p.m. | OK | Java 17 | TESTS | 5 | 233 | 614400 | ||
217367089 | aishwarykesarwani | A | Aug. 5, 2023, 6:36 p.m. | OK | Java 17 | TESTS | 5 | 249 | 204800 | ||
217376429 | aad40 | A | Aug. 5, 2023, 8:04 p.m. | OK | Java 17 | TESTS | 5 | 249 | 716800 | ||
217377410 | Y_T | A | Aug. 5, 2023, 8:15 p.m. | OK | Java 8 | TESTS | 5 | 77 | 0 | ||
217368934 | depurador_ik | A | Aug. 5, 2023, 6:53 p.m. | OK | Java 8 | TESTS | 5 | 93 | 0 | ||
217359215 | dhruvil8804 | A | Aug. 5, 2023, 5:39 p.m. | OK | Java 8 | TESTS | 5 | 108 | 0 | ||
217396221 | aFShahahahxx | A | Aug. 6, 2023, 2:28 a.m. | OK | Java 8 | TESTS | 5 | 109 | 0 | ||
217395194 | Sanat04 | A | Aug. 6, 2023, 2:11 a.m. | OK | Java 8 | TESTS | 5 | 109 | 0 | ||
217407977 | swastikverma308 | A | Aug. 6, 2023, 5:35 a.m. | OK | Java 8 | TESTS | 5 | 155 | 0 | ||
217368120 | rishabverma23 | A | Aug. 5, 2023, 6:46 p.m. | OK | Java 8 | TESTS | 5 | 155 | 0 | ||
217358725 | Juhaied_nabid | A | Aug. 5, 2023, 5:36 p.m. | OK | Java 8 | TESTS | 5 | 155 | 0 | ||
217359692 | jayesh_unde | A | Aug. 5, 2023, 5:42 p.m. | OK | Java 8 | TESTS | 5 | 171 | 0 | ||
217351018 | mokka_ganesh | A | Aug. 5, 2023, 4:33 p.m. | OK | Java 8 | TESTS | 5 | 217 | 0 | ||
217381618 | y04_bia | A | Aug. 5, 2023, 9:13 p.m. | OK | Kotlin 1.7 | TESTS | 5 | 326 | 6348800 | ||
217351805 | Saumya_706 | A | Aug. 5, 2023, 4:34 p.m. | OK | MS C++ 2017 | TESTS | 5 | 15 | 102400 | ||
217405231 | exilesome | A | Aug. 6, 2023, 4:58 a.m. | OK | MS C++ 2017 | TESTS | 5 | 31 | 0 | ||
217403004 | EtherealMidnight | A | Aug. 6, 2023, 4:23 a.m. | OK | MS C++ 2017 | TESTS | 5 | 31 | 0 | ||
217398945 | meiye | A | Aug. 6, 2023, 3:16 a.m. | OK | MS C++ 2017 | TESTS | 5 | 31 | 0 | ||
217389691 | bwgreen | A | Aug. 6, 2023, 12:04 a.m. | OK | MS C++ 2017 | TESTS | 5 | 31 | 0 | ||
217386028 | IvDmAl | A | Aug. 5, 2023, 10:35 p.m. | OK | MS C++ 2017 | TESTS | 5 | 31 | 0 | ||
217369304 | Kvazarus | A | Aug. 5, 2023, 6:57 p.m. | OK | MS C++ 2017 | TESTS | 5 | 31 | 0 | ||
217386701 | Dowtai | A | Aug. 5, 2023, 10:49 p.m. | OK | MS C++ 2017 | TESTS | 5 | 46 | 0 | ||
217370897 | tim.namikas | A | Aug. 5, 2023, 7:11 p.m. | OK | MS C++ 2017 | TESTS | 5 | 46 | 0 | ||
217365035 | Zeyad.AnkhAmon99 | A | Aug. 5, 2023, 6:20 p.m. | OK | MS C++ 2017 | TESTS | 5 | 46 | 0 | ||
217368169 | Yeasin_01 | A | Aug. 5, 2023, 6:46 p.m. | OK | Node.js | TESTS | 5 | 108 | 2560000 | ||
217364282 | dagmat | A | Aug. 5, 2023, 6:14 p.m. | OK | PyPy 3 | TESTS | 5 | 93 | 2662400 | ||
217405741 | letamquang220805 | A | Aug. 6, 2023, 5:05 a.m. | OK | PyPy 3 | TESTS | 5 | 139 | 3276800 | ||
217373954 | momenelmesady4803 | A | Aug. 5, 2023, 7:39 p.m. | OK | PyPy 3 | TESTS | 5 | 140 | 3993600 | ||
217402368 | erudition_0705 | A | Aug. 6, 2023, 4:12 a.m. | OK | PyPy 3 | TESTS | 5 | 140 | 5836800 | ||
217364061 | trizyx | A | Aug. 5, 2023, 6:12 p.m. | OK | PyPy 3 | TESTS | 5 | 170 | 5427200 | ||
217402127 | jawadkaleem1177 | A | Aug. 6, 2023, 4:08 a.m. | OK | PyPy 3 | TESTS | 5 | 171 | 5427200 | ||
217358024 | WalrusRamen21 | A | Aug. 5, 2023, 5:32 p.m. | OK | PyPy 3 | TESTS | 5 | 171 | 5939200 | ||
217363278 | trizyx | A | Aug. 5, 2023, 6:06 p.m. | OK | PyPy 3 | TESTS | 5 | 186 | 5427200 | ||
217370347 | daniil.gerchik | A | Aug. 5, 2023, 7:05 p.m. | OK | PyPy 3-64 | TESTS | 5 | 61 | 2150400 | ||
217371804 | daniil.gerchik | A | Aug. 5, 2023, 7:17 p.m. | OK | PyPy 3-64 | TESTS | 5 | 62 | 2560000 | ||
217408088 | Marco_Lau | A | Aug. 6, 2023, 5:36 a.m. | OK | PyPy 3-64 | TESTS | 5 | 62 | 3379200 | ||
217376214 | Cp_dead | A | Aug. 5, 2023, 8:01 p.m. | OK | PyPy 3-64 | TESTS | 5 | 62 | 3481600 | ||
217397598 | Youarenotgood | A | Aug. 6, 2023, 2:53 a.m. | OK | PyPy 3-64 | TESTS | 5 | 77 | 2764800 | ||
217382980 | injust | A | Aug. 5, 2023, 9:36 p.m. | OK | PyPy 3-64 | TESTS | 5 | 77 | 2764800 | ||
217396604 | zx4r | A | Aug. 6, 2023, 2:35 a.m. | OK | PyPy 3-64 | TESTS | 5 | 77 | 2867200 | ||
217358098 | I_Am_That | A | Aug. 5, 2023, 5:32 p.m. | OK | PyPy 3-64 | TESTS | 5 | 77 | 2867200 | ||
217369944 | AndreiZherder | A | Aug. 5, 2023, 7:01 p.m. | OK | PyPy 3-64 | TESTS | 5 | 77 | 2969600 | ||
217396743 | sorcerer_21 | A | Aug. 6, 2023, 2:38 a.m. | OK | PyPy 3-64 | TESTS | 5 | 77 | 3174400 | ||
217380569 | M_pro_M | A | Aug. 5, 2023, 8:56 p.m. | OK | Python 3 | TESTS | 5 | 30 | 409600 | ||
217366381 | ofdun | A | Aug. 5, 2023, 6:30 p.m. | OK | Python 3 | TESTS | 5 | 31 | 0 | ||
217407037 | aiza_k6 | A | Aug. 6, 2023, 5:23 a.m. | OK | Python 3 | TESTS | 5 | 31 | 409600 | ||
217375472 | FGTRK | A | Aug. 5, 2023, 7:53 p.m. | OK | Python 3 | TESTS | 5 | 31 | 409600 | ||
217367299 | bebo_y03 | A | Aug. 5, 2023, 6:38 p.m. | OK | Python 3 | TESTS | 5 | 31 | 409600 | ||
217378055 | M_pro_M | A | Aug. 5, 2023, 8:22 p.m. | OK | Python 3 | TESTS | 5 | 31 | 921600 | ||
217408648 | Athlete_7 | A | Aug. 6, 2023, 5:44 a.m. | OK | Python 3 | TESTS | 5 | 46 | 0 | ||
217405910 | akash20021118 | A | Aug. 6, 2023, 5:07 a.m. | OK | Python 3 | TESTS | 5 | 46 | 0 | ||
217404498 | xKRISHNAx | A | Aug. 6, 2023, 4:47 a.m. | OK | Python 3 | TESTS | 5 | 46 | 0 | ||
217390963 | Ashu_5 | A | Aug. 6, 2023, 12:41 a.m. | OK | Python 3 | TESTS | 5 | 46 | 0 | ||
217364110 | 0x81 | A | Aug. 5, 2023, 6:13 p.m. | OK | Ruby 3 | TESTS | 5 | 264 | 1024000 | ||
217373822 | cptahahab | A | Aug. 5, 2023, 7:38 p.m. | OK | Rust 2021 | TESTS | 5 | 15 | 0 |
Back to search problems