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 |
---|---|---|---|---|---|---|
1695 | Codeforces Round 801 (Div. 2) and EPIC Institute of Technology Round | FINISHED | False | 7200 | 81617063 | June 18, 2022, 2:35 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 18763 ) | B | Circle Game | PROGRAMMING | games | #Longest Path |
B'Mike and Joe are playing a game with some stones. Specifically, they have n piles of stones of sizes a_1, a_2, ldots, a_n . These piles are arranged in a circle. The game goes as follows. Players take turns removing some positive number of stones from a pile in clockwise order starting from pile 1 . Formally, if a player removed stones from pile i on a turn, the other player removes stones from pile ((i bmod n) + 1) on the next turn. If a player cannot remove any stones on their turn (because the pile is empty), they lose. Mike goes first. If Mike and Joe play optimally, who will win? Each test contains multiple test cases. The first line contains the number of test cases t ( 1 <= t <= 1000 ). Description of the test cases follows. The first line of each test case contains a single integer n ( 1 <= n <= 50 ) -- the number of piles. The second line contains n integers a_1, a_2, ldots, a_n ( 1 <= a_i <= 10^9 ) -- the size of the piles. For each test case print the winner of the game, either "Mike" or "Joe" on its own line (without quotes). In the first test case, Mike just takes all 37 stones on his first turn. In the second test case, Joe can just copy Mike 's moves every time. Since Mike went first, he will hit 0 on the first pile one move before Joe does so on the second pile. '... |
Editorial for Codeforces Round #801 (Div. 2) and EPIC Institute of Technology Round |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
161131146 | gxlois | B | June 18, 2022, 7:35 p.m. | OK | GNU C11 | TESTS | 49 | 31 | 0 | ||
161147916 | chinawcp | B | June 19, 2022, 4:11 a.m. | OK | GNU C11 | TESTS | 49 | 31 | 0 | ||
161110164 | aanjaimi | B | June 18, 2022, 4:20 p.m. | OK | GNU C11 | TESTS | 49 | 31 | 0 | ||
161111468 | Souradeep_Dey | B | June 18, 2022, 4:23 p.m. | OK | GNU C11 | TESTS | 49 | 31 | 0 | ||
161114527 | Param_1729 | B | June 18, 2022, 4:30 p.m. | OK | GNU C11 | TESTS | 49 | 31 | 0 | ||
161121670 | Ambh | B | June 18, 2022, 5:44 p.m. | OK | GNU C11 | TESTS | 49 | 31 | 0 | ||
161125934 | me_adon | B | June 18, 2022, 6:25 p.m. | OK | GNU C11 | TESTS | 49 | 31 | 0 | ||
161126546 | SadikMR | B | June 18, 2022, 6:33 p.m. | OK | GNU C11 | TESTS | 49 | 31 | 0 | ||
161132763 | shivam_751 | B | June 18, 2022, 8:03 p.m. | OK | GNU C++14 | TESTS | 49 | 15 | 0 | ||
161147917 | amanxjha_ | B | June 19, 2022, 4:11 a.m. | OK | GNU C++14 | TESTS | 49 | 15 | 0 | ||
161110788 | Vaishnavi_Pandey | B | June 18, 2022, 4:22 p.m. | OK | GNU C++14 | TESTS | 49 | 15 | 0 | ||
161144460 | duoluoluo | B | June 19, 2022, 2:43 a.m. | OK | GNU C++14 | TESTS | 49 | 15 | 0 | ||
161112236 | 594nb | B | June 18, 2022, 4:25 p.m. | OK | GNU C++14 | TESTS | 49 | 15 | 0 | ||
161137753 | 7oSkaaa | B | June 18, 2022, 10:16 p.m. | OK | GNU C++14 | TESTS | 49 | 15 | 0 | ||
161125157 | MechanicMistri | B | June 18, 2022, 6:17 p.m. | OK | GNU C++14 | TESTS | 49 | 15 | 204800 | ||
161114667 | hars_ | B | June 18, 2022, 4:30 p.m. | OK | GNU C++14 | TESTS | 49 | 15 | 204800 | ||
161144852 | the_ilyas | B | June 19, 2022, 2:54 a.m. | OK | GNU C++14 | TESTS | 49 | 15 | 204800 | ||
161133633 | NoInternetName | B | June 18, 2022, 8:23 p.m. | OK | GNU C++14 | TESTS | 49 | 15 | 204800 | ||
161130277 | asadcoder | B | June 18, 2022, 7:22 p.m. | OK | GNU C++17 | TESTS | 49 | 15 | 0 | ||
161126330 | GabrielXu | B | June 18, 2022, 6:30 p.m. | OK | GNU C++17 | TESTS | 49 | 15 | 0 | ||
161136288 | DeadPixel99 | B | June 18, 2022, 9:27 p.m. | OK | GNU C++17 | TESTS | 49 | 15 | 0 | ||
161138832 | toothless6104 | B | June 18, 2022, 11:02 p.m. | OK | GNU C++17 | TESTS | 49 | 15 | 0 | ||
161140283 | nguyendung30112003 | B | June 19, 2022, 12:07 a.m. | OK | GNU C++17 | TESTS | 49 | 15 | 0 | ||
161143309 | Hush | B | June 19, 2022, 2:10 a.m. | OK | GNU C++17 | TESTS | 49 | 15 | 0 | ||
161143903 | _nb_390 | B | June 19, 2022, 2:26 a.m. | OK | GNU C++17 | TESTS | 49 | 15 | 0 | ||
161150326 | Bunny_cal mandar.vardam6 sidjha57 | B | June 19, 2022, 5:04 a.m. | OK | GNU C++17 | TESTS | 49 | 15 | 0 | ||
161132017 | tushitapandey2001 | B | June 18, 2022, 7:50 p.m. | OK | GNU C++17 | TESTS | 49 | 15 | 0 | ||
161131313 | starboy_03 | B | June 18, 2022, 7:39 p.m. | OK | GNU C++17 | TESTS | 49 | 15 | 0 | ||
161139463 | DOngPH19 | B | June 18, 2022, 11:28 p.m. | OK | GNU C++17 (64) | TESTS | 49 | 15 | 0 | ||
161153208 | OTTFF | B | June 19, 2022, 5:49 a.m. | OK | GNU C++17 (64) | TESTS | 49 | 15 | 0 | ||
161151632 | nicolasalba | B | June 19, 2022, 5:25 a.m. | OK | GNU C++17 (64) | TESTS | 49 | 15 | 0 | ||
161149749 | hemanshu02 | B | June 19, 2022, 4:52 a.m. | OK | GNU C++17 (64) | TESTS | 49 | 15 | 0 | ||
161145504 | _Absurd_ | B | June 19, 2022, 3:13 a.m. | OK | GNU C++17 (64) | TESTS | 49 | 15 | 0 | ||
161139087 | moo. | B | June 18, 2022, 11:13 p.m. | OK | GNU C++17 (64) | TESTS | 49 | 15 | 0 | ||
161137522 | KeremTeke | B | June 18, 2022, 10:08 p.m. | OK | GNU C++17 (64) | TESTS | 49 | 15 | 0 | ||
161134931 | OnMyZenith | B | June 18, 2022, 8:53 p.m. | OK | GNU C++17 (64) | TESTS | 49 | 15 | 0 | ||
161134566 | bhatta.subhro | B | June 18, 2022, 8:46 p.m. | OK | GNU C++17 (64) | TESTS | 49 | 15 | 0 | ||
161134201 | LeeJiaHua | B | June 18, 2022, 8:37 p.m. | OK | GNU C++17 (64) | TESTS | 49 | 15 | 0 | ||
161149322 | ghihiihh | B | June 19, 2022, 4:43 a.m. | OK | GNU C++20 (64) | TESTS | 49 | 15 | 0 | ||
161148841 | Shahed_955 | B | June 19, 2022, 4:32 a.m. | OK | GNU C++20 (64) | TESTS | 49 | 15 | 0 | ||
161149340 | shihapfdim | B | June 19, 2022, 4:43 a.m. | OK | GNU C++20 (64) | TESTS | 49 | 15 | 0 | ||
161149680 | anandk543 | B | June 19, 2022, 4:51 a.m. | OK | GNU C++20 (64) | TESTS | 49 | 15 | 0 | ||
161149956 | don2001 | B | June 19, 2022, 4:56 a.m. | OK | GNU C++20 (64) | TESTS | 49 | 15 | 0 | ||
161151617 | Mushfiq_Talha | B | June 19, 2022, 5:25 a.m. | OK | GNU C++20 (64) | TESTS | 49 | 15 | 0 | ||
161151725 | Dog_food_is_me | B | June 19, 2022, 5:27 a.m. | OK | GNU C++20 (64) | TESTS | 49 | 15 | 0 | ||
161152344 | s_varun01 | B | June 19, 2022, 5:36 a.m. | OK | GNU C++20 (64) | TESTS | 49 | 15 | 0 | ||
161152412 | alok.kumar | B | June 19, 2022, 5:37 a.m. | OK | GNU C++20 (64) | TESTS | 49 | 15 | 0 | ||
161153737 | kajal_2610 | B | June 19, 2022, 5:57 a.m. | OK | GNU C++20 (64) | TESTS | 49 | 15 | 0 | ||
161153152 | gaju321 | B | June 19, 2022, 5:48 a.m. | OK | Java 11 | TESTS | 49 | 186 | 0 | ||
161142874 | Vegeks | B | June 19, 2022, 1:53 a.m. | OK | Java 11 | TESTS | 49 | 187 | 0 | ||
161143373 | churros | B | June 19, 2022, 2:12 a.m. | OK | Java 11 | TESTS | 49 | 187 | 0 | ||
161131844 | pras7946 | B | June 18, 2022, 7:47 p.m. | OK | Java 11 | TESTS | 49 | 187 | 0 | ||
161126174 | its_indus | B | June 18, 2022, 6:28 p.m. | OK | Java 11 | TESTS | 49 | 187 | 0 | ||
161125681 | nbhakar | B | June 18, 2022, 6:22 p.m. | OK | Java 11 | TESTS | 49 | 187 | 0 | ||
161133235 | limbutimbu | B | June 18, 2022, 8:14 p.m. | OK | Java 11 | TESTS | 49 | 202 | 0 | ||
161132825 | LoudSilence | B | June 18, 2022, 8:05 p.m. | OK | Java 11 | TESTS | 49 | 202 | 0 | ||
161147520 | gurkaran_s | B | June 19, 2022, 4:03 a.m. | OK | Java 11 | TESTS | 49 | 202 | 0 | ||
161127720 | pranp_24 | B | June 18, 2022, 6:46 p.m. | OK | Java 11 | TESTS | 49 | 202 | 0 | ||
161145906 | Zicode | B | June 19, 2022, 3:24 a.m. | OK | Java 8 | TESTS | 49 | 109 | 0 | ||
161134441 | ayafayed | B | June 18, 2022, 8:43 p.m. | OK | Java 8 | TESTS | 49 | 109 | 0 | ||
161130671 | abhinavTalesra | B | June 18, 2022, 7:28 p.m. | OK | Java 8 | TESTS | 49 | 109 | 0 | ||
161127923 | VishuTomar | B | June 18, 2022, 6:49 p.m. | OK | Java 8 | TESTS | 49 | 109 | 0 | ||
161121501 | priyaroy3370 | B | June 18, 2022, 5:43 p.m. | OK | Java 8 | TESTS | 49 | 109 | 0 | ||
161130822 | DylanSmith | B | June 18, 2022, 7:31 p.m. | OK | Java 8 | TESTS | 49 | 124 | 0 | ||
161144808 | josephSAMO | B | June 19, 2022, 2:53 a.m. | OK | Java 8 | TESTS | 49 | 124 | 0 | ||
161133632 | alv1 | B | June 18, 2022, 8:23 p.m. | OK | Java 8 | TESTS | 49 | 124 | 0 | ||
161121531 | Abdallah_Ragab00 | B | June 18, 2022, 5:43 p.m. | OK | Java 8 | TESTS | 49 | 124 | 0 | ||
161112086 | aryaman_571 | B | June 18, 2022, 4:25 p.m. | OK | Java 8 | TESTS | 49 | 124 | 0 | ||
161114303 | Guliash | B | June 18, 2022, 4:30 p.m. | OK | Kotlin 1.4 | TESTS | 49 | 155 | 0 | ||
161121281 | darkl0rd | B | June 18, 2022, 5:41 p.m. | OK | Kotlin 1.6 | TESTS | 49 | 202 | 0 | ||
161145976 | mohamedbakr | B | June 19, 2022, 3:26 a.m. | OK | Mono C# | TESTS | 49 | 62 | 3072000 | ||
161129520 | 1_shivam | B | June 18, 2022, 7:11 p.m. | OK | MS C++ 2017 | TESTS | 49 | 46 | 0 | ||
161114105 | wojciechkomor | B | June 18, 2022, 4:29 p.m. | OK | Node.js | TESTS | 49 | 93 | 5222400 | ||
161119508 | 1_2_3_4_5_9 | B | June 18, 2022, 5:30 p.m. | OK | PyPy 2 | TESTS | 49 | 140 | 2969600 | ||
161114974 | borodino | B | June 18, 2022, 4:31 p.m. | OK | PyPy 3 | TESTS | 49 | 140 | 3686400 | ||
161113377 | wizardrabbit | B | June 18, 2022, 4:28 p.m. | OK | PyPy 3 | TESTS | 49 | 140 | 3993600 | ||
161147641 | MohammadsadraSedighin | B | June 19, 2022, 4:05 a.m. | OK | PyPy 3 | TESTS | 49 | 217 | 7270400 | ||
161110379 | sahil329 | B | June 18, 2022, 4:21 p.m. | OK | PyPy 3 | TESTS | 49 | 234 | 7065600 | ||
161119458 | abhijeet.panihar.cse20 | B | June 18, 2022, 5:30 p.m. | OK | PyPy 3 | TESTS | 49 | 264 | 10854400 | ||
161124377 | Ayushman_123 | B | June 18, 2022, 6:09 p.m. | OK | PyPy 3 | TESTS | 49 | 280 | 6963200 | ||
161152185 | 3juhwan | B | June 19, 2022, 5:34 a.m. | OK | PyPy 3-64 | TESTS | 49 | 109 | 5529600 | ||
161136186 | _icy_ | B | June 18, 2022, 9:24 p.m. | OK | PyPy 3-64 | TESTS | 49 | 109 | 6451200 | ||
161123133 | aberent | B | June 18, 2022, 5:56 p.m. | OK | PyPy 3-64 | TESTS | 49 | 124 | 5836800 | ||
161109981 | iron_nicko | B | June 18, 2022, 4:20 p.m. | OK | PyPy 3-64 | TESTS | 49 | 124 | 5836800 | ||
161146449 | kryptosx | B | June 19, 2022, 3:37 a.m. | OK | PyPy 3-64 | TESTS | 49 | 124 | 6348800 | ||
161151161 | bridgekiller | B | June 19, 2022, 5:18 a.m. | OK | PyPy 3-64 | TESTS | 49 | 124 | 6656000 | ||
161133615 | biglunchdude | B | June 18, 2022, 8:23 p.m. | OK | PyPy 3-64 | TESTS | 49 | 124 | 6758400 | ||
161151403 | dunkin_shepherd | B | June 19, 2022, 5:22 a.m. | OK | PyPy 3-64 | TESTS | 49 | 139 | 7372800 | ||
161126619 | iwillgo | B | June 18, 2022, 6:33 p.m. | OK | PyPy 3-64 | TESTS | 49 | 171 | 10547200 | ||
161128545 | monsterrazzy | B | June 18, 2022, 6:58 p.m. | OK | PyPy 3-64 | TESTS | 49 | 186 | 9625600 | ||
161123288 | Jokezor | B | June 18, 2022, 5:58 p.m. | OK | Python 3 | TESTS | 49 | 61 | 0 | ||
161143213 | DaRk_hEaRt_ | B | June 19, 2022, 2:07 a.m. | OK | Python 3 | TESTS | 49 | 61 | 307200 | ||
161151349 | Vishal1336 | B | June 19, 2022, 5:21 a.m. | OK | Python 3 | TESTS | 49 | 62 | 0 | ||
161148704 | vinaymit | B | June 19, 2022, 4:29 a.m. | OK | Python 3 | TESTS | 49 | 62 | 0 | ||
161147369 | MohaSa | B | June 19, 2022, 3:59 a.m. | OK | Python 3 | TESTS | 49 | 62 | 0 | ||
161145610 | KamruzzamanAsif | B | June 19, 2022, 3:16 a.m. | OK | Python 3 | TESTS | 49 | 62 | 0 | ||
161144449 | Pratneeee | B | June 19, 2022, 2:43 a.m. | OK | Python 3 | TESTS | 49 | 62 | 0 | ||
161142330 | narasimha_1406 | B | June 19, 2022, 1:35 a.m. | OK | Python 3 | TESTS | 49 | 62 | 0 | ||
161140939 | monu_dixit | B | June 19, 2022, 12:40 a.m. | OK | Python 3 | TESTS | 49 | 62 | 0 | ||
161138099 | darklordtn | B | June 18, 2022, 10:31 p.m. | OK | Python 3 | TESTS | 49 | 62 | 0 | ||
161109886 | sansen | B | June 18, 2022, 4:19 p.m. | OK | Rust 2021 | TESTS | 49 | 15 | 2048000 |
Back to search problems