Codeforces Round 616 (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
1291 Codeforces Round 616 (Div. 2) FINISHED False 9000 156700511 Feb. 2, 2020, 2:05 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 14363 ) B Array Sharpening PROGRAMMING greedy implementation 1300

B'You 're given an array a_1, ldots, a_n of n non-negative integers. Let 's call it sharpened if and only if there exists an integer 1 <= k <= n such that a_1 < a_2 < ldots < a_k and a_k > a_{k+1} > ldots > a_n . In particular, any strictly increasing or strictly decreasing array is sharpened. For example: You can do the following operation as many times as you want: choose any strictly positive element of the array, and decrease it by one. Formally, you can choose any i ( 1 <= i <= n ) such that a_i>0 and assign a_i := a_i - 1 . Tell if it 's possible to make the given array sharpened using some number (possibly zero) of these operations. The input consists of multiple test cases. The first line contains a single integer t ( 1 <= t <= 15 000 ) -- the number of test cases. The description of the test cases follows. The first line of each test case contains a single integer n ( 1 <= n <= 3 cdot 10^5 ). The second line of each test case contains a sequence of n non-negative integers a_1, ldots, a_n ( 0 <= a_i <= 10^9 ). It is guaranteed that the sum of n over all test cases does not exceed 3 cdot 10^5 . For each test case, output a single line containing "Yes" (without quotes) if it 's possible to make the given array sharpened using the described operations, or "No" (without quotes) otherwise. In the first and the second test case of the first test, the given array is already sharpened. In the third test case of the first test, we can transform the array into [3, 11, 15, 9, 7, 4] (decrease the first element 97 times and decrease the last element 4 times). It is sharpened because 3 < 11 < 15 and 15 > 9 > 7 > 4 . In the fourth test case of the first test, it 's impossible to make the given array sharpened. '...

Tutorials

Codeforces Round #616 Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
70820176 541907010414 B Feb. 12, 2020, 3:15 a.m. OK Clang++17 Diagnostics TESTS 14 155 102400 1300
70205907 xianglli B Feb. 4, 2020, 6:22 a.m. OK Clang++17 Diagnostics TESTS 14 155 307200 1300
71076213 ftiasch B Feb. 14, 2020, 5:23 p.m. OK D TESTS 14 78 22118400 1300
70104068 manhduc B Feb. 3, 2020, 2 a.m. OK FPC TESTS 14 93 1228800 1300
70052381 Lycfucking. B Feb. 2, 2020, 2:44 p.m. OK FPC TESTS 14 93 2048000 1300
70068630 755352046 B Feb. 2, 2020, 3:31 p.m. OK GNU C11 TESTS 14 62 1228800 1300
70627381 mth1908 B Feb. 9, 2020, 1:39 p.m. OK GNU C11 TESTS 14 77 1228800 1300
70066464 Wrong_Wizzli B Feb. 2, 2020, 3:23 p.m. OK GNU C11 TESTS 14 77 1228800 1300
70067004 thegreatkwanghyeon B Feb. 2, 2020, 3:25 p.m. OK GNU C11 TESTS 14 77 1228800 1300
70073784 31901179 B Feb. 2, 2020, 3:51 p.m. OK GNU C11 TESTS 14 77 1228800 1300
70218116 TARIQ B Feb. 4, 2020, 10:20 a.m. OK GNU C11 TESTS 14 77 1228800 1300
70218754 TARIQ B Feb. 4, 2020, 10:32 a.m. OK GNU C11 TESTS 14 77 1228800 1300
70068743 Enthusiasticcitizens B Feb. 2, 2020, 3:32 p.m. OK GNU C11 TESTS 14 77 1638400 1300
70076786 hnust_jinyan B Feb. 2, 2020, 4:03 p.m. OK GNU C11 TESTS 14 77 2457600 1300
70369644 f20190414 B Feb. 5, 2020, 2:57 p.m. OK GNU C11 TESTS 14 77 4096000 1300
70056814 guowendi060222 B Feb. 2, 2020, 2:55 p.m. OK GNU C++11 TESTS 14 30 2252800 1300
70061179 ljr1234 B Feb. 2, 2020, 3:07 p.m. OK GNU C++11 TESTS 14 31 614400 1300
70347015 _Clouder B Feb. 5, 2020, 9:51 a.m. OK GNU C++11 TESTS 14 31 1024000 1300
70067269 kpgong B Feb. 2, 2020, 3:26 p.m. OK GNU C++11 TESTS 14 31 1024000 1300
70727118 luogu_bot3 B Feb. 10, 2020, 12:13 p.m. OK GNU C++11 TESTS 14 31 1228800 1300
70323980 yuzhechuan B Feb. 5, 2020, 2:22 a.m. OK GNU C++11 TESTS 14 31 1228800 1300
70107386 Lanly B Feb. 3, 2020, 3:54 a.m. OK GNU C++11 TESTS 14 31 1228800 1300
70822931 Taday B Feb. 12, 2020, 4:59 a.m. OK GNU C++11 TESTS 14 31 1228800 1300
70727205 Xposed B Feb. 10, 2020, 12:14 p.m. OK GNU C++11 TESTS 14 31 1228800 1300
70328790 Famvics B Feb. 5, 2020, 5 a.m. OK GNU C++11 TESTS 14 31 1228800 1300
70133951 angrysqrt3 B Feb. 3, 2020, 11:13 a.m. OK GNU C++14 TESTS 14 62 1228800 1300
70767569 vjudge1 B Feb. 11, 2020, 5:35 a.m. OK GNU C++14 TESTS 14 62 1228800 1300
71054453 WorLone B Feb. 14, 2020, 11:12 a.m. OK GNU C++14 TESTS 14 62 1228800 1300
70062207 houguanli B Feb. 2, 2020, 3:10 p.m. OK GNU C++14 TESTS 14 62 1228800 1300
70477675 dy2000 B Feb. 7, 2020, 4:37 a.m. OK GNU C++14 TESTS 14 77 1228800 1300
70068821 BigO1 B Feb. 2, 2020, 3:32 p.m. OK GNU C++14 TESTS 14 77 1433600 1300
70051775 liv_curious B Feb. 2, 2020, 2:42 p.m. OK GNU C++14 TESTS 14 77 2355200 1300
70075650 include42 B Feb. 2, 2020, 3:58 p.m. OK GNU C++14 TESTS 14 77 2355200 1300
70083870 xiaoziyao B Feb. 2, 2020, 4:32 p.m. OK GNU C++14 TESTS 14 77 3584000 1300
70445043 momoofhappiness B Feb. 6, 2020, 2:56 p.m. OK GNU C++14 TESTS 14 78 0 1300
70052442 Alphagocc B Feb. 2, 2020, 2:44 p.m. OK GNU C++17 TESTS 14 31 1740800 1300
70086325 tokitsukaze B Feb. 2, 2020, 5:11 p.m. OK GNU C++17 TESTS 14 46 3686400 1300
70080091 playerzmr B Feb. 2, 2020, 4:17 p.m. OK GNU C++17 TESTS 14 46 4505600 1300
70067781 yc0304 B Feb. 2, 2020, 3:28 p.m. OK GNU C++17 TESTS 14 61 1228800 1300
71071373 HHH793 B Feb. 14, 2020, 3:59 p.m. OK GNU C++17 TESTS 14 62 1126400 1300
70468963 Awsaf_BRUR11 B Feb. 6, 2020, 10:11 p.m. OK GNU C++17 TESTS 14 62 1126400 1300
70105390 hzeroto B Feb. 3, 2020, 2:51 a.m. OK GNU C++17 TESTS 14 62 1228800 1300
70050020 cjhxqdt B Feb. 2, 2020, 2:38 p.m. OK GNU C++17 TESTS 14 62 1228800 1300
70105561 heshuo. B Feb. 3, 2020, 2:56 a.m. OK GNU C++17 TESTS 14 62 1228800 1300
70130663 CQXYM B Feb. 3, 2020, 10:23 a.m. OK GNU C++17 TESTS 14 62 1228800 1300
70068963 naipia B Feb. 2, 2020, 3:32 p.m. OK Go TESTS 14 93 4505600 1300
70053760 synapse B Feb. 2, 2020, 2:47 p.m. OK Go TESTS 14 249 4505600 1300
70078065 ontake B Feb. 2, 2020, 4:08 p.m. OK Go TESTS 14 280 4505600 1300
70050015 j31d0 B Feb. 2, 2020, 2:38 p.m. OK Haskell TESTS 14 935 63078400 1300
70114887 Anonymous B Feb. 3, 2020, 6:49 a.m. OK Java 11 TESTS 14 186 0 1300
70076652 kaushal_jalan B Feb. 2, 2020, 4:02 p.m. OK Java 11 TESTS 14 187 0 1300
70110225 devesh08 B Feb. 3, 2020, 5:14 a.m. OK Java 11 TESTS 14 202 0 1300
70055900 avijit_agarwal B Feb. 2, 2020, 2:52 p.m. OK Java 11 TESTS 14 202 0 1300
70074318 saurabh0611 B Feb. 2, 2020, 3:53 p.m. OK Java 11 TESTS 14 233 0 1300
70066683 elkadymohammed01 B Feb. 2, 2020, 3:24 p.m. OK Java 11 TESTS 14 233 4096000 1300
70056092 Azakarka B Feb. 2, 2020, 2:53 p.m. OK Java 11 TESTS 14 233 4096000 1300
70071325 arran B Feb. 2, 2020, 3:41 p.m. OK Java 11 TESTS 14 234 8192000 1300
70055194 Oom B Feb. 2, 2020, 2:51 p.m. OK Java 11 TESTS 14 248 3993600 1300
70070084 alankritanand001 B Feb. 2, 2020, 3:36 p.m. OK Java 11 TESTS 14 249 4096000 1300
70087413 prem_cse B Feb. 2, 2020, 5:24 p.m. OK Java 8 TESTS 14 124 0 1300
70511601 iamyashh B Feb. 7, 2020, 3:01 p.m. OK Java 8 TESTS 14 124 0 1300
70461291 Nirav412000 B Feb. 6, 2020, 6:46 p.m. OK Java 8 TESTS 14 124 0 1300
70165011 Apurva021 B Feb. 3, 2020, 4:16 p.m. OK Java 8 TESTS 14 124 0 1300
70150849 rahsutamrev B Feb. 3, 2020, 12:56 p.m. OK Java 8 TESTS 14 124 0 1300
70132023 bluesky111 B Feb. 3, 2020, 10:39 a.m. OK Java 8 TESTS 14 124 0 1300
70129914 arsh1598 B Feb. 3, 2020, 10:12 a.m. OK Java 8 TESTS 14 124 0 1300
70113155 In_The_Name_Of_Love B Feb. 3, 2020, 6:17 a.m. OK Java 8 TESTS 14 124 0 1300
70096112 Modi_sarkar B Feb. 2, 2020, 8:18 p.m. OK Java 8 TESTS 14 124 0 1300
70092442 Bhavya_Arora B Feb. 2, 2020, 6:52 p.m. OK Java 8 TESTS 14 124 0 1300
70079777 macolby14 B Feb. 2, 2020, 4:16 p.m. OK JavaScript TESTS 14 171 33177600 1300
70065582 Rinat_ B Feb. 2, 2020, 3:21 p.m. OK JavaScript TESTS 14 171 35737600 1300
70104472 Spheniscine B Feb. 3, 2020, 2:16 a.m. OK Kotlin TESTS 14 187 14643200 1300
70506662 Rolion B Feb. 7, 2020, 1:44 p.m. OK Kotlin TESTS 14 467 34508800 1300
70596056 david_varela B Feb. 9, 2020, 12:10 a.m. OK Kotlin TESTS 14 499 35635200 1300
70573554 nastya1199 B Feb. 8, 2020, 3:01 p.m. OK Mono C# TESTS 14 155 32972800 1300
70212534 TRR B Feb. 4, 2020, 8:42 a.m. OK Mono C# TESTS 14 155 33075200 1300
70050681 sergmel B Feb. 2, 2020, 2:40 p.m. OK Mono C# TESTS 14 170 33075200 1300
70070098 shy3205 B Feb. 2, 2020, 3:36 p.m. OK Mono C# TESTS 14 171 39731200 1300
70458949 mytas B Feb. 6, 2020, 6:10 p.m. OK Mono C# TESTS 14 171 40857600 1300
70564524 sakapon B Feb. 8, 2020, 12:50 p.m. OK Mono C# TESTS 14 171 40960000 1300
70147745 artworks B Feb. 3, 2020, 12:11 p.m. OK Mono C# TESTS 14 171 41984000 1300
70059166 plasma-effect B Feb. 2, 2020, 3:01 p.m. OK Mono C# TESTS 14 186 40960000 1300
70075285 tvvister B Feb. 2, 2020, 3:57 p.m. OK Mono C# TESTS 14 187 40857600 1300
70774418 vjudge5 B Feb. 11, 2020, 8:20 a.m. OK MS C++ TESTS 14 62 1228800 1300
70432779 vjudge3 B Feb. 6, 2020, 12:03 p.m. OK MS C++ TESTS 14 62 3584000 1300
70419874 vjudge3 B Feb. 6, 2020, 8:21 a.m. OK MS C++ TESTS 14 77 1228800 1300
70062707 wangziyue111 B Feb. 2, 2020, 3:12 p.m. OK MS C++ TESTS 14 77 1228800 1300
70533621 tarattata1 B Feb. 8, 2020, 1:06 a.m. OK MS C++ TESTS 14 77 2355200 1300
70124032 vjudge4 B Feb. 3, 2020, 9:32 a.m. OK MS C++ TESTS 14 77 2457600 1300
70054529 accwxhn B Feb. 2, 2020, 2:49 p.m. OK MS C++ TESTS 14 77 3584000 1300
70414566 vjudge4 B Feb. 6, 2020, 6:38 a.m. OK MS C++ TESTS 14 78 1228800 1300
70051757 songhaoran B Feb. 2, 2020, 2:42 p.m. OK MS C++ TESTS 14 139 1228800 1300
70066502 samnever B Feb. 2, 2020, 3:24 p.m. OK MS C++ TESTS 14 140 0 1300
70070643 lyzdxh B Feb. 2, 2020, 3:38 p.m. OK MS C++ 2017 TESTS 14 93 0 1300
70086405 ram_bharose_jindgi_bitao B Feb. 2, 2020, 5:12 p.m. OK MS C++ 2017 TESTS 14 93 1228800 1300
70101958 wjsrptmd B Feb. 3, 2020, 12:16 a.m. OK MS C++ 2017 TESTS 14 93 1228800 1300
70103310 hnust_chenjunyu B Feb. 3, 2020, 1:28 a.m. OK MS C++ 2017 TESTS 14 93 1228800 1300
70103530 jtsncpp B Feb. 3, 2020, 1:37 a.m. OK MS C++ 2017 TESTS 14 93 1228800 1300
70108933 paradoxhzy B Feb. 3, 2020, 4:39 a.m. OK MS C++ 2017 TESTS 14 93 2662400 1300
70087779 pichulia B Feb. 2, 2020, 5:29 p.m. OK MS C++ 2017 TESTS 14 93 6041600 1300
70071020 cursed B Feb. 2, 2020, 3:40 p.m. OK MS C++ 2017 TESTS 14 108 1228800 1300
70071463 shigehanhan B Feb. 2, 2020, 3:41 p.m. OK MS C++ 2017 TESTS 14 108 1433600 1300
70937102 vjudge3 B Feb. 13, 2020, 7:05 a.m. OK MS C++ 2017 TESTS 14 108 1433600 1300
70060321 sanori B Feb. 2, 2020, 3:04 p.m. OK Node.js TESTS 14 374 27136000 1300
70169098 rsFalse B Feb. 3, 2020, 5:02 p.m. OK Perl TESTS 14 545 68710400 1300
70572973 mayakin B Feb. 8, 2020, 2:52 p.m. OK PHP TESTS 14 93 35328000 1300
70206593 Gaurav1 B Feb. 4, 2020, 6:38 a.m. OK PyPy 2 TESTS 14 202 30720000 1300
70083307 c1729 B Feb. 2, 2020, 4:30 p.m. OK PyPy 2 TESTS 14 234 22016000 1300
70058014 iamprayush B Feb. 2, 2020, 2:58 p.m. OK PyPy 2 TESTS 14 327 31232000 1300
70052954 11fingers B Feb. 2, 2020, 2:45 p.m. OK PyPy 2 TESTS 14 374 18944000 1300
70060453 ashok123 B Feb. 2, 2020, 3:05 p.m. OK PyPy 2 TESTS 14 405 18944000 1300
70074580 WhatsCode B Feb. 2, 2020, 3:54 p.m. OK PyPy 2 TESTS 14 561 27955200 1300
70078403 m.ni B Feb. 2, 2020, 4:10 p.m. OK PyPy 3 TESTS 14 389 22220800 1300
70073460 GatienC B Feb. 2, 2020, 3:49 p.m. OK PyPy 3 TESTS 14 404 27955200 1300
70062351 sirgavila B Feb. 2, 2020, 3:10 p.m. OK PyPy 3 TESTS 14 405 20684800 1300
70068275 vaibhavsarda B Feb. 2, 2020, 3:30 p.m. OK PyPy 3 TESTS 14 405 23961600 1300
70083248 a0976531005 B Feb. 2, 2020, 4:30 p.m. OK PyPy 3 TESTS 14 405 26828800 1300
70064861 qalaiqalai B Feb. 2, 2020, 3:18 p.m. OK PyPy 3 TESTS 14 420 20275200 1300
70092019 shubham26857 B Feb. 2, 2020, 6:43 p.m. OK PyPy 3 TESTS 14 420 23961600 1300
70236648 FahimSifnatul B Feb. 4, 2020, 1:45 p.m. OK PyPy 3 TESTS 14 420 26214400 1300
70050745 Pedantic B Feb. 2, 2020, 2:40 p.m. OK PyPy 3 TESTS 14 420 26316800 1300
70089150 Munchy_1 B Feb. 2, 2020, 5:50 p.m. OK PyPy 3 TESTS 14 420 26828800 1300
70077442 bravotango B Feb. 2, 2020, 4:06 p.m. OK Python 3 TESTS 14 218 27136000 1300
70056721 nandakrishna75 B Feb. 2, 2020, 2:54 p.m. OK Python 3 TESTS 14 234 24268800 1300
70060223 terrafarm B Feb. 2, 2020, 3:04 p.m. OK Python 3 TESTS 14 249 24268800 1300
70070584 BUCT_WynnLu B Feb. 2, 2020, 3:38 p.m. OK Python 3 TESTS 14 249 24576000 1300
70069670 Joggor B Feb. 2, 2020, 3:35 p.m. OK Python 3 TESTS 14 249 24576000 1300
70149318 justAmanGupta B Feb. 3, 2020, 12:35 p.m. OK Python 3 TESTS 14 264 24268800 1300
70207826 prsb123 B Feb. 4, 2020, 7:04 a.m. OK Python 3 TESTS 14 264 24576000 1300
70076350 ganba B Feb. 2, 2020, 4:01 p.m. OK Python 3 TESTS 14 264 24576000 1300
70057411 elya.tkd.itf B Feb. 2, 2020, 2:56 p.m. OK Python 3 TESTS 14 264 24576000 1300
70102337 jackowitzd2 B Feb. 3, 2020, 12:40 a.m. OK Python 3 TESTS 14 265 24268800 1300
70066445 f67 B Feb. 2, 2020, 3:23 p.m. OK Ruby TESTS 14 420 59494400 1300
70054017 simanman B Feb. 2, 2020, 2:48 p.m. OK Ruby TESTS 14 514 57958400 1300
70099856 motoras B Feb. 2, 2020, 10:26 p.m. OK Rust TESTS 14 62 23347200 1300
70080574 Nogard_ B Feb. 2, 2020, 4:19 p.m. OK Rust TESTS 14 171 10240000 1300
70072011 hir12111 B Feb. 2, 2020, 3:44 p.m. OK Rust TESTS 14 187 23449600 1300

remove filters

Back to search problems