Codeforces Round 662 (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
1393 Codeforces Round 662 (Div. 2) FINISHED False 7200 140369063 Aug. 7, 2020, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 10701 ) C Pinkie Pie Eats Patty-cakes PROGRAMMING binary search constructive algorithms data structures greedy math sortings

B"Pinkie Pie has bought a bag of patty-cakes with different fillings! But it appeared that not all patty-cakes differ from one another with filling. In other words, the bag contains some patty-cakes with the same filling. Pinkie Pie eats the patty-cakes one-by-one. She likes having fun so she decided not to simply eat the patty-cakes but to try not to eat the patty-cakes with the same filling way too often. To achieve this she wants the minimum distance between the eaten with the same filling to be the largest possible. Herein Pinkie Pie called the distance between two patty-cakes the number of eaten patty-cakes strictly between them. Pinkie Pie can eat the patty-cakes in any order. She is impatient about eating all the patty-cakes up so she asks you to help her to count the greatest minimum distance between the eaten patty-cakes with the same filling amongst all possible orders of eating! Pinkie Pie is going to buy more bags of patty-cakes so she asks you to solve this problem for several bags! The first line contains a single integer T ( 1 <= T <= 100 ): the number of bags for which you need to solve the problem. The first line of each bag description contains a single integer n ( 2 <= n <= 10^5 ): the number of patty-cakes in it. The second line of the bag description contains n integers a_1, a_2, ldots, a_n ( 1 <= a_i <= n ): the information of patty-cakes' fillings: same fillings are defined as same integers, different fillings are defined as different integers. It is guaranteed that each bag contains at least two patty-cakes with the same filling. It is guaranteed that the sum of n over all bags does not exceed 10^5 . For each bag print in separate line one single integer: the largest minimum distance between the eaten patty-cakes with the same filling amongst all possible orders of eating for that bag. For the first bag Pinkie Pie can eat the patty-cakes in the following order (by fillings): 1$"...

Tutorials

Codeforces Round #662 Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
89600775 gxlois C Aug. 11, 2020, 6 p.m. OK D TESTS 63 62 28979200
90176660 rr_ C Aug. 16, 2020, 8:43 p.m. OK D TESTS 63 655 55296000
89358144 xyzyzl_ C Aug. 8, 2020, 6:52 p.m. OK GNU C11 TESTS 63 46 4096000
89389155 ajoydey00001 C Aug. 9, 2020, 9:37 a.m. OK GNU C11 TESTS 63 46 4300800
90839008 prokofitch C Aug. 24, 2020, 3:22 p.m. OK GNU C11 TESTS 63 46 7680000
89573607 gilesg C Aug. 11, 2020, 11:44 a.m. OK GNU C11 TESTS 63 62 4710400
89470297 JoseTomas01 C Aug. 9, 2020, 11:45 p.m. OK GNU C11 TESTS 63 62 84172800
90440882 vjudge1 C Aug. 20, 2020, 7:12 a.m. OK GNU C++11 TESTS 63 31 409600
90012178 levill C Aug. 15, 2020, 10:57 a.m. OK GNU C++11 TESTS 63 31 2457600
89368590 chenshi028 C Aug. 9, 2020, 1:47 a.m. OK GNU C++11 TESTS 63 31 4096000
89368885 luogu_bot3 C Aug. 9, 2020, 2:01 a.m. OK GNU C++11 TESTS 63 31 4096000
89367874 CZJ_2005 C Aug. 9, 2020, 1:05 a.m. OK GNU C++11 TESTS 63 31 4300800
89470310 luogu_bot4 C Aug. 9, 2020, 11:46 p.m. OK GNU C++11 TESTS 63 31 4505600
90592155 luogu_bot4 C Aug. 21, 2020, 3:43 p.m. OK GNU C++11 TESTS 63 31 4505600
90503601 vjudge5 C Aug. 21, 2020, 3:21 a.m. OK GNU C++11 TESTS 63 31 4505600
89496441 JasonLan C Aug. 10, 2020, 9:14 a.m. OK GNU C++11 TESTS 63 31 4710400
91462042 wuruzhao C Aug. 31, 2020, 6:11 a.m. OK GNU C++11 TESTS 63 31 4710400
91118031 ConferenceCall C Aug. 27, 2020, 8:54 a.m. OK GNU C++14 TESTS 63 31 921600
91267129 bansalkanha68 C Aug. 29, 2020, 8:07 a.m. OK GNU C++14 TESTS 63 46 409600
90057110 nitvjudge4 C Aug. 16, 2020, 4:56 a.m. OK GNU C++14 TESTS 63 46 409600
89788150 vjudge5 C Aug. 13, 2020, 11:23 a.m. OK GNU C++14 TESTS 63 46 409600
90901038 zhanghonghe3 C Aug. 25, 2020, 1 p.m. OK GNU C++14 TESTS 63 46 819200
90402500 201824115141 C Aug. 19, 2020, 3:33 p.m. OK GNU C++14 TESTS 63 46 819200
89788532 vjudge5 C Aug. 13, 2020, 11:28 a.m. OK GNU C++14 TESTS 63 46 819200
91635191 Sambhu.98 C Sept. 2, 2020, 11:21 a.m. OK GNU C++14 TESTS 63 46 819200
90001372 dinesh_verra C Aug. 15, 2020, 8:27 a.m. OK GNU C++14 TESTS 63 46 1638400
91711020 omhari C Sept. 3, 2020, 11:12 a.m. OK GNU C++14 TESTS 63 46 3174400
89853456 Clouder0 C Aug. 14, 2020, 8:16 a.m. OK GNU C++17 TESTS 63 31 1740800
89742278 black_pearl98 C Aug. 12, 2020, 8:12 p.m. OK GNU C++17 TESTS 63 46 409600
91277405 RUMAZIUS C Aug. 29, 2020, 10:43 a.m. OK GNU C++17 TESTS 63 46 409600
90059053 huhst2020_003 C Aug. 16, 2020, 5:45 a.m. OK GNU C++17 TESTS 63 46 409600
90045413 ghost_Ishav C Aug. 15, 2020, 8:33 p.m. OK GNU C++17 TESTS 63 46 409600
90000175 HaGeza C Aug. 15, 2020, 8:12 a.m. OK GNU C++17 TESTS 63 46 409600
89743702 Siddharth2020 C Aug. 12, 2020, 8:43 p.m. OK GNU C++17 TESTS 63 46 409600
89792725 hey_its_archit C Aug. 13, 2020, 12:21 p.m. OK GNU C++17 TESTS 63 46 512000
91046422 tjrac6019203189 Fau818 TJ6019203128 C Aug. 26, 2020, 11:39 a.m. OK GNU C++17 TESTS 63 46 614400
91553726 Azadpurbey C Sept. 1, 2020, 9:46 a.m. OK GNU C++17 TESTS 63 46 819200
90015042 sharrad99 C Aug. 15, 2020, 11:40 a.m. OK GNU C++17 (64) TESTS 63 46 819200
89495161 Sakif C Aug. 10, 2020, 8:53 a.m. OK GNU C++17 (64) TESTS 63 46 4710400
89477061 Sakhiya07 C Aug. 10, 2020, 3:42 a.m. OK GNU C++17 (64) TESTS 63 46 4710400
89467443 FflashkingF C Aug. 9, 2020, 9:22 p.m. OK GNU C++17 (64) TESTS 63 46 4710400
89381526 Koo_ C Aug. 9, 2020, 7:31 a.m. OK GNU C++17 (64) TESTS 63 46 4710400
89566391 clearlove20 C Aug. 11, 2020, 9:48 a.m. OK GNU C++17 (64) TESTS 63 46 4710400
89536158 smurfer C Aug. 10, 2020, 9:09 p.m. OK GNU C++17 (64) TESTS 63 46 4710400
89532624 chitrung1 C Aug. 10, 2020, 7:35 p.m. OK GNU C++17 (64) TESTS 63 46 4710400
89504901 Tikhon228 C Aug. 10, 2020, 11:31 a.m. OK GNU C++17 (64) TESTS 63 46 4710400
89499403 Raeee C Aug. 10, 2020, 10:03 a.m. OK GNU C++17 (64) TESTS 63 46 4710400
90760494 Trishan C Aug. 23, 2020, 1:48 p.m. OK Go TESTS 63 61 16691200
89540409 jc881203 C Aug. 11, 2020, 12:29 a.m. OK Go TESTS 63 62 15974400
89851581 RetiredProgrammer C Aug. 14, 2020, 7:46 a.m. OK Go TESTS 63 1809 4915200
89391115 kunalkatiyar9 C Aug. 9, 2020, 10:12 a.m. OK Java 11 TESTS 63 186 23756800
91171847 DR.KOKS C Aug. 28, 2020, 12:12 a.m. OK Java 11 TESTS 63 202 0
91170905 DR.KOKS C Aug. 27, 2020, 11:15 p.m. OK Java 11 TESTS 63 202 0
90479710 jayesh_patil C Aug. 20, 2020, 4:09 p.m. OK Java 11 TESTS 63 202 0
89461548 mm.devin.wang C Aug. 9, 2020, 6:44 p.m. OK Java 11 TESTS 63 202 24064000
89387410 jongheon C Aug. 9, 2020, 9:07 a.m. OK Java 11 TESTS 63 218 24064000
89467659 anubhav44044 C Aug. 9, 2020, 9:31 p.m. OK Java 11 TESTS 63 218 25907200
89608330 sam_abbas80 C Aug. 11, 2020, 8:43 p.m. OK Java 11 TESTS 63 249 26112000
89373422 skittles1412 C Aug. 9, 2020, 4:43 a.m. OK Java 11 TESTS 63 265 31334400
90863478 Justyo C Aug. 25, 2020, 2:50 a.m. OK Java 11 TESTS 63 280 8908800
90006805 Nirav412000 C Aug. 15, 2020, 9:39 a.m. OK Java 8 TESTS 63 109 0
91184337 tarun_sm C Aug. 28, 2020, 6:28 a.m. OK Java 8 TESTS 63 124 0
91153989 n3o-d4rk3r C Aug. 27, 2020, 4:56 p.m. OK Java 8 TESTS 63 124 0
89976634 bluesky111 C Aug. 14, 2020, 11:09 p.m. OK Java 8 TESTS 63 124 0
89875975 vjvjain0 C Aug. 14, 2020, 1:55 p.m. OK Java 8 TESTS 63 124 0
89374178 sizzula C Aug. 9, 2020, 5:04 a.m. OK Java 8 TESTS 63 124 20275200
89561415 subhash.yadav C Aug. 11, 2020, 8:28 a.m. OK Java 8 TESTS 63 124 20377600
89378789 honeysingh18 C Aug. 9, 2020, 6:47 a.m. OK Java 8 TESTS 63 124 20377600
89355791 Samez C Aug. 8, 2020, 6:08 p.m. OK Java 8 TESTS 63 124 20480000
91332817 alpha000 C Aug. 30, 2020, 10:11 a.m. OK Java 8 TESTS 63 124 20582400
89353638 Spheniscine C Aug. 8, 2020, 5:26 p.m. OK Kotlin TESTS 63 155 22220800
89575415 ZeroAmbition C Aug. 11, 2020, 12:12 p.m. OK Kotlin TESTS 63 233 24268800
89508286 koper C Aug. 10, 2020, 12:20 p.m. OK Kotlin TESTS 63 280 27545600
89367553 a11eca C Aug. 9, 2020, 12:46 a.m. OK Kotlin TESTS 63 311 27136000
89534426 dkozak94 C Aug. 10, 2020, 8:17 p.m. OK Kotlin TESTS 63 795 40960000
89534344 dkozak94 C Aug. 10, 2020, 8:15 p.m. OK Kotlin TESTS 63 1138 44134400
89805944 azukun C Aug. 13, 2020, 3:05 p.m. OK Mono C# TESTS 63 373 24576000
91204920 jagajang C Aug. 28, 2020, 11:56 a.m. OK MS C++ 2017 TESTS 63 61 4403200
89557979 zjut201906150333zyf C Aug. 11, 2020, 7:37 a.m. OK MS C++ 2017 TESTS 63 62 4403200
91253241 minigimbob C Aug. 29, 2020, 3:32 a.m. OK MS C++ 2017 TESTS 63 93 409600
91250715 wonbin0504 C Aug. 29, 2020, 2 a.m. OK MS C++ 2017 TESTS 63 93 1024000
89798949 vjudge4 C Aug. 13, 2020, 1:39 p.m. OK MS C++ 2017 TESTS 63 93 1126400
89373092 Biang-Biang C Aug. 9, 2020, 4:32 a.m. OK MS C++ 2017 TESTS 63 108 4096000
89609123 icecap360 C Aug. 11, 2020, 9:07 p.m. OK MS C++ 2017 TESTS 63 108 4505600
89406109 zhangwen123 C Aug. 9, 2020, 2:23 p.m. OK MS C++ 2017 TESTS 63 108 6144000
91136147 Explode C Aug. 27, 2020, 1:21 p.m. OK MS C++ 2017 TESTS 63 109 2048000
89395144 ustaritz C Aug. 9, 2020, 11:20 a.m. OK MS C++ 2017 TESTS 63 109 4505600
90472517 tutai C Aug. 20, 2020, 2:44 p.m. OK Node.js TESTS 63 171 9420800
89363497 realnimish C Aug. 8, 2020, 9:16 p.m. OK PyPy 2 TESTS 63 202 31027200
89873536 iamprayush C Aug. 14, 2020, 1:18 p.m. OK PyPy 2 TESTS 63 218 14848000
90284487 ELLZO C Aug. 18, 2020, 7:07 a.m. OK PyPy 3 TESTS 63 187 10854400
90431238 mmhaxor1 C Aug. 20, 2020, 4:10 a.m. OK PyPy 3 TESTS 63 202 10752000
91573611 aarish C Sept. 1, 2020, 2:23 p.m. OK PyPy 3 TESTS 63 202 11980800
89627091 abhinay007 C Aug. 12, 2020, 6:36 a.m. OK PyPy 3 TESTS 63 202 30924800
89351572 anubhavsinha98 C Aug. 8, 2020, 4:46 p.m. OK PyPy 3 TESTS 63 202 31539200
89586228 macdod C Aug. 11, 2020, 2:36 p.m. OK PyPy 3 TESTS 63 202 32051200
89354649 Anuranjan_Pandey C Aug. 8, 2020, 5:46 p.m. OK PyPy 3 TESTS 63 202 32972800
89360551 iamnavya_agg C Aug. 8, 2020, 7:49 p.m. OK PyPy 3 TESTS 63 202 33484800
90079715 Alice_Synthesis C Aug. 16, 2020, 12:01 p.m. OK PyPy 3 TESTS 63 218 12083200
89795115 vinayak333 C Aug. 13, 2020, 12:51 p.m. OK PyPy 3 TESTS 63 218 12185600
89464183 thuglife69 C Aug. 9, 2020, 7:40 p.m. OK Python 2 TESTS 63 592 13004800
90489438 rishi_saraswat C Aug. 20, 2020, 6:33 p.m. OK Python 3 TESTS 63 155 7680000
89568143 linlin000 C Aug. 11, 2020, 10:17 a.m. OK Python 3 TESTS 63 155 14438400
89373866 imraghav20 C Aug. 9, 2020, 4:56 a.m. OK Python 3 TESTS 63 155 14438400
89518549 nowrin_brown C Aug. 10, 2020, 2:36 p.m. OK Python 3 TESTS 63 155 17305600
90370002 Katushechka C Aug. 19, 2020, 8:09 a.m. OK Python 3 TESTS 63 156 7680000
89386680 sakshatmali C Aug. 9, 2020, 8:55 a.m. OK Python 3 TESTS 63 156 14028800
89393033 LeoPro C Aug. 9, 2020, 10:45 a.m. OK Python 3 TESTS 63 156 14131200
89601984 Semakov C Aug. 11, 2020, 6:21 p.m. OK Python 3 TESTS 63 156 15667200
89374631 tinku10 C Aug. 9, 2020, 5:16 a.m. OK Python 3 TESTS 63 156 16384000
90889254 sayuyere C Aug. 25, 2020, 10:10 a.m. OK Python 3 TESTS 63 171 9011200
89386522 xodeChemist C Aug. 9, 2020, 8:52 a.m. OK Ruby TESTS 63 577 59904000
89385295 pandrei C Aug. 9, 2020, 8:33 a.m. OK Rust TESTS 63 46 8089600
89772402 Strorkis C Aug. 13, 2020, 7:50 a.m. OK Rust TESTS 63 93 3686400

remove filters

Back to search problems