Codeforces Round 893 (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
1858 Codeforces Round 893 (Div. 2) FINISHED False 7200 45069863 Aug. 15, 2023, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 11661 ) B The Walkway PROGRAMMING brute force greedy implementation math number theory 1500

B'There are n benches near the Main Walkway in Summer Infomatics School. These benches are numbered by integers from 1 to n in order they follow. Also there are m cookie sellers near the Walkway. The i -th ( 1 <= i <= m ) cookie sellers is located near the s_i -th bench. Petya is standing in the beginning of the Walkway. He will pass near all benches starting from the 1 -st bench and ending with the n -th bench. Petya passes the distance between two consecutive benches in 1 minute. He has a knapsack with an infinite amount of cookies. Petya is going to eat cookies from his knapsack and buy them from cookie sellers during the walk. Petya eats cookies only near the benches according to the following rule: he will eat the cookie near the i -th ( 1 <= i <= n ) bench if and only if at least one of the following conditions holds: You may assume that Petya eats cookies instantly. Petya will not eat two or more cookies near the same bench. You want to minimize the number of cookies Petya will eat during his walk. In order to do this, you will ask the administration of the Summer Informatics School to remove exactly one cookie seller from the Walkway before Petya starts his walk. Please determine the minimum possible number of cookies Petya can eat after removing exactly one cookie seller. Also determine the number of cookie sellers, such that if you remove one of them, Petya will eat the minimum possible number of cookies. The first line contains a single integer t ( 1 <= t <= 10^3 ) -- the number of test cases. The first line of each test case contains three integers n , m and d ( 2 <= d <= n <= 10^9 , 2 <= m <= min(10^{5}, n) ) -- the number of benches, the number of cookie sellers and the value of parameter d from the statement, respectively. The second line of each test case contains m integers s_1, s_2, ldots, s_m ( 1 <= s_i '...

Tutorials

Codeforces Round #893 (Div. 2) Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
219018765 kirsider B Aug. 15, 2023, 7:32 p.m. OK C# 10 TESTS 14 93 8601600 1500
218995623 AutumnMist B Aug. 15, 2023, 4:28 p.m. OK C# 10 TESTS 14 93 14745600 1500
219018422 Its_All_Up_To_U B Aug. 15, 2023, 7:28 p.m. OK Clang++20 Diagnostics TESTS 14 77 7372800 1500
219033712 Leasier B Aug. 16, 2023, 12:40 a.m. OK GNU C11 TESTS 14 31 409600 1500
219029635 iffatul_anon B Aug. 15, 2023, 10:55 p.m. OK GNU C11 TESTS 14 46 1638400 1500
219029550 iffatul_anon B Aug. 15, 2023, 10:53 p.m. OK GNU C11 TESTS 14 46 1638400 1500
219032212 JBJF B Aug. 16, 2023, 12:07 a.m. OK GNU C++14 TESTS 14 30 409600 1500
219049567 wws20040810 B Aug. 16, 2023, 3:38 a.m. OK GNU C++14 TESTS 14 30 2048000 1500
219052185 starrykiller B Aug. 16, 2023, 4:13 a.m. OK GNU C++14 TESTS 14 31 409600 1500
219051723 ABlyh B Aug. 16, 2023, 4:06 a.m. OK GNU C++14 TESTS 14 31 409600 1500
219051185 zhuzc B Aug. 16, 2023, 3:59 a.m. OK GNU C++14 TESTS 14 31 409600 1500
219050551 xqdzFred B Aug. 16, 2023, 3:51 a.m. OK GNU C++14 TESTS 14 31 409600 1500
219049176 X_F_H B Aug. 16, 2023, 3:34 a.m. OK GNU C++14 TESTS 14 31 409600 1500
219058165 chenyilai B Aug. 16, 2023, 5:27 a.m. OK GNU C++14 TESTS 14 31 409600 1500
219053337 _Hella_ B Aug. 16, 2023, 4:29 a.m. OK GNU C++14 TESTS 14 31 409600 1500
219059375 mRXxy0u0 B Aug. 16, 2023, 5:40 a.m. OK GNU C++14 TESTS 14 31 409600 1500
219003834 TimmyChiang B Aug. 15, 2023, 5:14 p.m. OK GNU C++17 TESTS 14 30 409600 1500
219027300 arnavwinner B Aug. 15, 2023, 9:51 p.m. OK GNU C++17 TESTS 14 30 409600 1500
219017374 chenreddy B Aug. 15, 2023, 7:16 p.m. OK GNU C++17 TESTS 14 30 819200 1500
219023154 Hawater B Aug. 15, 2023, 8:32 p.m. OK GNU C++17 TESTS 14 30 1126400 1500
219039391 vrehg B Aug. 16, 2023, 2:03 a.m. OK GNU C++17 TESTS 14 30 1536000 1500
218995293 nik_agarwal12 B Aug. 15, 2023, 4:27 p.m. OK GNU C++17 TESTS 14 30 2048000 1500
219054327 kehuanenrong B Aug. 16, 2023, 4:42 a.m. OK GNU C++17 TESTS 14 31 409600 1500
219056569 shadow9236 B Aug. 16, 2023, 5:08 a.m. OK GNU C++17 TESTS 14 31 409600 1500
219055227 cypher_king B Aug. 16, 2023, 4:53 a.m. OK GNU C++17 TESTS 14 31 409600 1500
219059916 xyzTiger B Aug. 16, 2023, 5:46 a.m. OK GNU C++17 TESTS 14 31 409600 1500
219052981 Rosemary B Aug. 16, 2023, 4:24 a.m. OK GNU C++17 (64) TESTS 14 15 409600 1500
219053432 rahul_o15 B Aug. 16, 2023, 4:30 a.m. OK GNU C++17 (64) TESTS 14 15 2048000 1500
219053536 KRISH_FOUSC B Aug. 16, 2023, 4:32 a.m. OK GNU C++17 (64) TESTS 14 15 2355200 1500
219053951 BoaHancock B Aug. 16, 2023, 4:37 a.m. OK GNU C++17 (64) TESTS 14 15 2560000 1500
219003700 lunchbox B Aug. 15, 2023, 5:13 p.m. OK GNU C++17 (64) TESTS 14 30 409600 1500
219038989 Sy_03 B Aug. 16, 2023, 2 a.m. OK GNU C++17 (64) TESTS 14 30 409600 1500
218997222 qmsio B Aug. 15, 2023, 4:31 p.m. OK GNU C++17 (64) TESTS 14 30 819200 1500
219026773 kauperwood B Aug. 15, 2023, 9:39 p.m. OK GNU C++17 (64) TESTS 14 30 819200 1500
219018565 Endless_love_for_Helena B Aug. 15, 2023, 7:30 p.m. OK GNU C++17 (64) TESTS 14 30 819200 1500
218999843 A.0121 B Aug. 15, 2023, 4:34 p.m. OK GNU C++17 (64) TESTS 14 30 1638400 1500
219049699 wly666... B Aug. 16, 2023, 3:40 a.m. OK GNU C++20 (64) TESTS 14 15 409600 1500
219047355 ndeweixinghuang B Aug. 16, 2023, 3:12 a.m. OK GNU C++20 (64) TESTS 14 15 409600 1500
219043592 koorui B Aug. 16, 2023, 2:37 a.m. OK GNU C++20 (64) TESTS 14 15 409600 1500
219040990 Robbe B Aug. 16, 2023, 2:18 a.m. OK GNU C++20 (64) TESTS 14 15 409600 1500
219040317 zhangfish B Aug. 16, 2023, 2:12 a.m. OK GNU C++20 (64) TESTS 14 15 409600 1500
219039064 Libra. B Aug. 16, 2023, 2 a.m. OK GNU C++20 (64) TESTS 14 15 409600 1500
219029465 takbir-hasan B Aug. 15, 2023, 10:50 p.m. OK GNU C++20 (64) TESTS 14 15 409600 1500
219052019 BuddhaBarFans B Aug. 16, 2023, 4:11 a.m. OK GNU C++20 (64) TESTS 14 15 409600 1500
219056593 Ali.R B Aug. 16, 2023, 5:09 a.m. OK GNU C++20 (64) TESTS 14 15 409600 1500
219059780 namcartoon06 B Aug. 16, 2023, 5:45 a.m. OK GNU C++20 (64) TESTS 14 15 409600 1500
219013658 lorenzotinfena B Aug. 15, 2023, 6:35 p.m. OK Go TESTS 14 62 3174400 1500
219025274 kushwaha_vi B Aug. 15, 2023, 9:09 p.m. OK Java 11 TESTS 14 187 0 1500
219016358 themadknight45 B Aug. 15, 2023, 7:05 p.m. OK Java 11 TESTS 14 202 0 1500
219009033 sangledurvesh21 B Aug. 15, 2023, 5:52 p.m. OK Java 11 TESTS 14 218 0 1500
219050875 pakkapapad B Aug. 16, 2023, 3:55 a.m. OK Java 11 TESTS 14 233 0 1500
219031377 Harwinvanak B Aug. 15, 2023, 11:48 p.m. OK Java 11 TESTS 14 233 0 1500
219012433 EricM08 B Aug. 15, 2023, 6:22 p.m. OK Java 11 TESTS 14 233 0 1500
218994817 codingIsFun1234 B Aug. 15, 2023, 4:26 p.m. OK Java 11 TESTS 14 233 0 1500
219053426 TJ_Codes B Aug. 16, 2023, 4:30 a.m. OK Java 11 TESTS 14 249 0 1500
219034872 Harwinvanak B Aug. 16, 2023, 1:02 a.m. OK Java 11 TESTS 14 249 0 1500
219015901 dzhi B Aug. 15, 2023, 7 p.m. OK Java 11 TESTS 14 249 0 1500
219039751 Ligh0x74 B Aug. 16, 2023, 2:07 a.m. OK Java 17 TESTS 14 217 409600 1500
219027682 mlangc B Aug. 15, 2023, 10 p.m. OK Java 17 TESTS 14 233 307200 1500
219023095 raito3z B Aug. 15, 2023, 8:31 p.m. OK Java 17 TESTS 14 233 307200 1500
219038131 Ligh0x74 B Aug. 16, 2023, 1:49 a.m. OK Java 17 TESTS 14 233 819200 1500
219005878 ahmed.elbakly B Aug. 15, 2023, 5:27 p.m. OK Java 17 TESTS 14 233 4608000 1500
219007793 ahmed.elbakly B Aug. 15, 2023, 5:41 p.m. OK Java 17 TESTS 14 233 4812800 1500
219015400 Akash_Sardar B Aug. 15, 2023, 6:54 p.m. OK Java 17 TESTS 14 234 4096000 1500
219023011 _ryan18_ B Aug. 15, 2023, 8:30 p.m. OK Java 17 TESTS 14 264 614400 1500
219022472 tushar19280 B Aug. 15, 2023, 8:22 p.m. OK Java 17 TESTS 14 265 40652800 1500
219024400 diamond5687 B Aug. 15, 2023, 8:52 p.m. OK Java 17 TESTS 14 280 512000 1500
219013095 faresbadr316 B Aug. 15, 2023, 6:29 p.m. OK Java 8 TESTS 14 109 0 1500
219024430 American_Eagle B Aug. 15, 2023, 8:53 p.m. OK Java 8 TESTS 14 124 0 1500
219012565 vatsal_04 B Aug. 15, 2023, 6:23 p.m. OK Java 8 TESTS 14 124 0 1500
219012067 RonWonWon B Aug. 15, 2023, 6:18 p.m. OK Java 8 TESTS 14 124 0 1500
219018845 yadavDipesh B Aug. 15, 2023, 7:33 p.m. OK Java 8 TESTS 14 140 0 1500
219008817 This_is_Rish B Aug. 15, 2023, 5:50 p.m. OK Java 8 TESTS 14 155 4608000 1500
219013555 Sumitsingh7 B Aug. 15, 2023, 6:34 p.m. OK Java 8 TESTS 14 155 6041600 1500
219058568 priyaroy3370 B Aug. 16, 2023, 5:32 a.m. OK Java 8 TESTS 14 171 716800 1500
218994690 Yousef_Badr B Aug. 15, 2023, 4:26 p.m. OK Java 8 TESTS 14 218 0 1500
219017979 utkrsh2212 B Aug. 15, 2023, 7:23 p.m. OK Java 8 TESTS 14 264 0 1500
219024497 Ncato_Del_Gormo7 B Aug. 15, 2023, 8:54 p.m. OK MS C++ 2017 TESTS 14 78 1228800 1500
218997983 Vitya.saber B Aug. 15, 2023, 4:32 p.m. OK MS C++ 2017 TESTS 14 78 1228800 1500
219045280 wry9852022 B Aug. 16, 2023, 2:52 a.m. OK MS C++ 2017 TESTS 14 78 1843200 1500
219015281 KuriyamaShiro B Aug. 15, 2023, 6:53 p.m. OK MS C++ 2017 TESTS 14 78 2560000 1500
219045679 wry9852022 B Aug. 16, 2023, 2:55 a.m. OK MS C++ 2017 TESTS 14 93 1843200 1500
219004024 Antwerp2004 B Aug. 15, 2023, 5:15 p.m. OK MS C++ 2017 TESTS 14 93 3584000 1500
219044958 Tokai_Teio. B Aug. 16, 2023, 2:50 a.m. OK MS C++ 2017 TESTS 14 109 1228800 1500
218996380 BusIgor B Aug. 15, 2023, 4:29 p.m. OK MS C++ 2017 TESTS 14 109 1638400 1500
219040275 RSL459 B Aug. 16, 2023, 2:12 a.m. OK MS C++ 2017 TESTS 14 109 3174400 1500
219029662 Adham0 B Aug. 15, 2023, 10:56 p.m. OK PHP TESTS 14 202 16793600 1500
219035569 Gaurav1 B Aug. 16, 2023, 1:14 a.m. OK PyPy 2 TESTS 14 234 12185600 1500
219018087 Tururutu B Aug. 15, 2023, 7:24 p.m. OK PyPy 3 TESTS 14 265 12902400 1500
219016851 zechri B Aug. 15, 2023, 7:11 p.m. OK PyPy 3-64 TESTS 14 93 13312000 1500
219046168 Turtleeee B Aug. 16, 2023, 2:59 a.m. OK PyPy 3-64 TESTS 14 108 14233600 1500
219017711 plevande B Aug. 15, 2023, 7:20 p.m. OK PyPy 3-64 TESTS 14 108 18944000 1500
219017338 zechri B Aug. 15, 2023, 7:16 p.m. OK PyPy 3-64 TESTS 14 109 14233600 1500
219015213 bergus B Aug. 15, 2023, 6:52 p.m. OK PyPy 3-64 TESTS 14 109 18841600 1500
219024941 rmr B Aug. 15, 2023, 9:04 p.m. OK PyPy 3-64 TESTS 14 124 11059200 1500
219025091 khalit7 B Aug. 15, 2023, 9:06 p.m. OK PyPy 3-64 TESTS 14 124 13721600 1500
219053163 Youarenotgood B Aug. 16, 2023, 4:27 a.m. OK PyPy 3-64 TESTS 14 124 14233600 1500
219032221 sami02jain B Aug. 16, 2023, 12:07 a.m. OK PyPy 3-64 TESTS 14 124 15872000 1500
219021056 Quick-One B Aug. 15, 2023, 8:02 p.m. OK PyPy 3-64 TESTS 14 124 17920000 1500
219018411 alexpods B Aug. 15, 2023, 7:28 p.m. OK Python 3 TESTS 14 124 12800000 1500
219009304 guntehi B Aug. 15, 2023, 5:54 p.m. OK Python 3 TESTS 14 140 12800000 1500
218998681 thomasbijucheeramvelil B Aug. 15, 2023, 4:33 p.m. OK Python 3 TESTS 14 140 12902400 1500
219016242 alexpods B Aug. 15, 2023, 7:04 p.m. OK Python 3 TESTS 14 155 14233600 1500
219045030 21wh1a0211 B Aug. 16, 2023, 2:50 a.m. OK Python 3 TESTS 14 156 12800000 1500
219016498 rushi_javiya B Aug. 15, 2023, 7:07 p.m. OK Python 3 TESTS 14 171 12800000 1500
219010680 SS_CM B Aug. 15, 2023, 6:06 p.m. OK Python 3 TESTS 14 171 12800000 1500
218997129 smqdcf B Aug. 15, 2023, 4:31 p.m. OK Python 3 TESTS 14 171 12902400 1500
218995879 hanbro0112 B Aug. 15, 2023, 4:28 p.m. OK Python 3 TESTS 14 187 12800000 1500
219016596 alexpods B Aug. 15, 2023, 7:08 p.m. OK Python 3 TESTS 14 202 12800000 1500
218994862 console.shivam B Aug. 15, 2023, 4:26 p.m. OK Ruby 3 TESTS 14 389 8089600 1500
218999444 pavanisr51 B Aug. 15, 2023, 4:34 p.m. OK Ruby 3 TESTS 14 498 9113600 1500
219008458 sky B Aug. 15, 2023, 5:47 p.m. OK Rust 2021 TESTS 14 15 7782400 1500
218998116 aditya_coder9 B Aug. 15, 2023, 4:32 p.m. OK Rust 2021 TESTS 14 31 4198400 1500
219033376 utkspartan B Aug. 16, 2023, 12:32 a.m. OK Scala TESTS 14 919 5939200 1500
219033311 utkspartan B Aug. 16, 2023, 12:31 a.m. OK Scala TESTS 14 920 7168000 1500

remove filters

Back to search problems