CodeTON Round 2 (Div. 1 + Div. 2, Rated, Prizes!)

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
1704 CodeTON Round 2 (Div. 1 + Div. 2, Rated, Prizes!) FINISHED False 9000 77903663 July 31, 2022, 2:05 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 1077 ) F Colouring Game PROGRAMMING constructive algorithms games

B"Alice and Bob are playing a game. There are n cells in a row. Initially each cell is either red or blue. Alice goes first. On each turn, Alice chooses two neighbouring cells which contain at least one red cell, and paints that two cells white. Then, Bob chooses two neighbouring cells which contain at least one blue cell, and paints that two cells white. The player who cannot make a move loses. Find the winner if both Alice and Bob play optimally. Note that a chosen cell can be white, as long as the other cell satisfies the constraints. The first line contains a single integer t ( 1 <= q t <= q 10^4 ) -- the number of test cases. Description of test cases follows. For each test case, the first line contains an integer n ( 2 <= q n <= q 5 cdot 10^5 ) -- the number of cells. The second line contains a string s of length n -- the initial state of the cells. The i -th cell is red if s_i = R, blue if s_i = B. It is guaranteed that the sum of n over all test cases does not exceed 5 cdot 10^5 . For each test case, output the name of the winner on a separate line. In the notes, the cell numbers increase from left to right. In the first testcase for Alice, she has two choices: paint the first and the second cells, or paint the second and the third cells. No matter what choice Alice makes, there will be exactly one blue cell after Alice's move. Bob just needs to paint the blue cell and its neighbour, then every cell will be white and Alice can't make a move. So Bob is the winner. In the second testcase no matter what Alice chooses, Bob can choose to paint the fourth and fifth cells in 2 turns. In the third testcase at first, Alice paints the third and the fourth cells. It doesn't matter if Bob paints the first and the second cells or the fifth and sixth cells, as Alice can paint the other two cells. In the fourth testcase at first, Alice paints the second and the third cells. If Bob paints"...

Tutorials

CodeTON Round 2 Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
166406258 hos.lyric F July 31, 2022, 6:16 p.m. OK D TESTS 64 62 6144000
166392031 PurpleWonder F July 31, 2022, 3:56 p.m. OK GNU C++14 TESTS 64 15 4505600
166440917 czyer F Aug. 1, 2022, 4:57 a.m. OK GNU C++14 TESTS 64 31 512000
166429853 L7-56 F Aug. 1, 2022, 1:52 a.m. OK GNU C++14 TESTS 64 31 512000
166409312 temp06 F July 31, 2022, 6:44 p.m. OK GNU C++14 TESTS 64 31 512000
166406974 KrK F July 31, 2022, 6:21 p.m. OK GNU C++14 TESTS 64 31 512000
166397983 Uagu F July 31, 2022, 4:25 p.m. OK GNU C++14 TESTS 64 31 512000
166408573 Venn F July 31, 2022, 6:36 p.m. OK GNU C++14 TESTS 64 31 1024000
166433246 xuanxuan001 F Aug. 1, 2022, 2:47 a.m. OK GNU C++14 TESTS 64 31 2457600
166398266 harinboy F July 31, 2022, 4:27 p.m. OK GNU C++14 TESTS 64 31 2457600
166433906 wsyhb F Aug. 1, 2022, 2:57 a.m. OK GNU C++14 TESTS 64 31 2560000
166421124 deutzia F July 31, 2022, 10:13 p.m. OK GNU C++17 TESTS 64 30 614400
166420226 patou F July 31, 2022, 9:33 p.m. OK GNU C++17 TESTS 64 30 1024000
166389743 275307894b F July 31, 2022, 3:45 p.m. OK GNU C++17 TESTS 64 31 512000
166428402 praeteriti F Aug. 1, 2022, 1:30 a.m. OK GNU C++17 TESTS 64 31 1024000
166406906 TheLostCookie F July 31, 2022, 6:21 p.m. OK GNU C++17 TESTS 64 31 1024000
166397382 tamionv F July 31, 2022, 4:23 p.m. OK GNU C++17 TESTS 64 31 1024000
166388575 jjang36524 F July 31, 2022, 3:40 p.m. OK GNU C++17 TESTS 64 31 1024000
166385431 alireza_kaviani F July 31, 2022, 3:28 p.m. OK GNU C++17 TESTS 64 31 1024000
166410200 Kaitokid F July 31, 2022, 6:55 p.m. OK GNU C++17 TESTS 64 31 1228800
166409751 Kaitokid F July 31, 2022, 6:50 p.m. OK GNU C++17 TESTS 64 31 1228800
166406166 huangxiaohua F July 31, 2022, 6:16 p.m. OK GNU C++17 (64) TESTS 64 30 1024000
166434997 timmyfeng F Aug. 1, 2022, 3:15 a.m. OK GNU C++17 (64) TESTS 64 30 3072000
166423414 SevenDawns F July 31, 2022, 11:29 p.m. OK GNU C++17 (64) TESTS 64 31 512000
166429184 errorgorn F Aug. 1, 2022, 1:42 a.m. OK GNU C++17 (64) TESTS 64 31 1024000
166416979 prokopton F July 31, 2022, 8:33 p.m. OK GNU C++17 (64) TESTS 64 31 1024000
166399743 AutumnKite F July 31, 2022, 4:33 p.m. OK GNU C++17 (64) TESTS 64 31 1024000
166396357 LittleCube F July 31, 2022, 4:17 p.m. OK GNU C++17 (64) TESTS 64 31 1024000
166395067 potato167 F July 31, 2022, 4:11 p.m. OK GNU C++17 (64) TESTS 64 31 1024000
166388991 kotatsugame F July 31, 2022, 3:42 p.m. OK GNU C++17 (64) TESTS 64 31 1024000
166406004 tabr F July 31, 2022, 6:15 p.m. OK GNU C++17 (64) TESTS 64 31 1536000
166431111 BeyondHeaven F Aug. 1, 2022, 2:13 a.m. OK GNU C++20 (64) TESTS 64 15 1024000
166388901 AndreySergunin F July 31, 2022, 3:41 p.m. OK GNU C++20 (64) TESTS 64 15 1024000
166386899 Endagorion F July 31, 2022, 3:33 p.m. OK GNU C++20 (64) TESTS 64 15 1024000
166396480 yarik_mutltiacc F July 31, 2022, 4:18 p.m. OK GNU C++20 (64) TESTS 64 15 2252800
166431362 H01yK_ F Aug. 1, 2022, 2:17 a.m. OK GNU C++20 (64) TESTS 64 15 3072000
166434981 lx_tyin F Aug. 1, 2022, 3:14 a.m. OK GNU C++20 (64) TESTS 64 15 3276800
166405474 JovanB F July 31, 2022, 6:12 p.m. OK GNU C++20 (64) TESTS 64 15 4096000
166409585 S2speed F July 31, 2022, 6:47 p.m. OK GNU C++20 (64) TESTS 64 15 5120000
166394521 sohsoh F July 31, 2022, 4:08 p.m. OK GNU C++20 (64) TESTS 64 15 5120000
166434153 _Cade_ F Aug. 1, 2022, 3:01 a.m. OK GNU C++20 (64) TESTS 64 30 1024000
166399809 SecondThread F July 31, 2022, 4:34 p.m. OK Java 8 TESTS 64 155 38297600
166389850 Tlatoani F July 31, 2022, 3:46 p.m. OK Kotlin 1.6 TESTS 64 343 2048000
166389830 arvindf232 F July 31, 2022, 3:45 p.m. OK Kotlin 1.6 TESTS 64 358 0
166384557 PavelKunyavskiy F July 31, 2022, 3:24 p.m. OK Kotlin 1.6 TESTS 64 374 15769600
166388984 __Happy__ F July 31, 2022, 3:42 p.m. OK PyPy 3-64 TESTS 64 389 10547200
166425505 Arsen4ikVar F Aug. 1, 2022, 12:34 a.m. OK PyPy 3-64 TESTS 64 389 15667200
166389413 sansen F July 31, 2022, 3:44 p.m. OK Rust 2021 TESTS 64 31 2150400

remove filters

Back to search problems