Codeforces Round 938 (Div. 3)

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
1955 Codeforces Round 938 (Div. 3) FINISHED False 8100 24593063 April 8, 2024, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 7373 ) F Unfair Game PROGRAMMING dp games greedy math

B"Alice and Bob gathered in the evening to play an exciting game on a sequence of n integers, each integer of the sequence doesn't exceed 4 . The rules of the game are too complex to describe, so let's just describe the winning condition -- Alice wins if the bitwise XOR of all the numbers in the sequence is non-zero; otherwise, Bob wins. The guys invited Eve to act as a judge. Initially, Alice and Bob play with n numbers. After one game, Eve removes one of the numbers from the sequence, then Alice and Bob play with n-1 numbers. Eve removes one number again, after which Alice and Bob play with n - 2 numbers. This continues until the sequence of numbers is empty. Eve seems to think that in such a game, Alice almost always wins, so she wants Bob to win as many times as possible. Determine the maximum number of times Bob can win against Alice if Eve removes the numbers optimally. The first line contains an integer t ( 1 <= t <= 10^4 ) -- the number of test cases. The first and only line of each test case contains four integers p_i ( 0 <= p_i <= 200 ) -- the number of ones, twos, threes, and fours in the sequence at the beginning of the game. For each test case, print the maximum number of times Bob will win in a separate line, if Eve removes the numbers optimally. In the first example, Bob wins when Eve has not removed any numbers yet. In the second example, Bob wins if Eve removes one one and one three. "...

Tutorials

128243

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
255822789 exitkhan F April 9, 2024, 5:35 a.m. OK C++14 (GCC 6-32) TESTS 10 46 102400
255813463 Nanako7_ix F April 9, 2024, 3:49 a.m. OK C++14 (GCC 6-32) TESTS 10 46 102400
255809693 Bree_Cui F April 9, 2024, 3:03 a.m. OK C++14 (GCC 6-32) TESTS 10 46 102400
255807757 zhou_2009 F April 9, 2024, 2:36 a.m. OK C++14 (GCC 6-32) TESTS 10 46 102400
255812228 yuyc F April 9, 2024, 3:34 a.m. OK C++14 (GCC 6-32) TESTS 10 61 102400
255810000 vijay_mali F April 9, 2024, 3:06 a.m. OK C++14 (GCC 6-32) TESTS 10 62 0
255805532 chtholly3 F April 9, 2024, 2:05 a.m. OK C++14 (GCC 6-32) TESTS 10 62 0
255824242 qyzy F April 9, 2024, 5:49 a.m. OK C++14 (GCC 6-32) TESTS 10 62 102400
255809353 dangidevanshu F April 9, 2024, 2:58 a.m. OK C++14 (GCC 6-32) TESTS 10 62 102400
255801282 waleedalaa511 F April 9, 2024, 12:53 a.m. OK C++14 (GCC 6-32) TESTS 10 62 102400
255821268 NXDXML F April 9, 2024, 5:21 a.m. OK C++17 (GCC 7-32) TESTS 10 46 0
255820207 sbzx F April 9, 2024, 5:10 a.m. OK C++17 (GCC 7-32) TESTS 10 46 0
255818265 sanyam2248 F April 9, 2024, 4:50 a.m. OK C++17 (GCC 7-32) TESTS 10 46 0
255812353 ZiFeii F April 9, 2024, 3:36 a.m. OK C++17 (GCC 7-32) TESTS 10 46 0
255810861 azureboy F April 9, 2024, 3:16 a.m. OK C++17 (GCC 7-32) TESTS 10 46 0
255809992 mo1234560 F April 9, 2024, 3:06 a.m. OK C++17 (GCC 7-32) TESTS 10 46 0
255809421 shenchuan_fan F April 9, 2024, 2:59 a.m. OK C++17 (GCC 7-32) TESTS 10 46 0
255808983 magicaltitan F April 9, 2024, 2:53 a.m. OK C++17 (GCC 7-32) TESTS 10 46 0
255807317 sjnnjs F April 9, 2024, 2:32 a.m. OK C++17 (GCC 7-32) TESTS 10 46 0
255805394 sahil_beck F April 9, 2024, 2:03 a.m. OK C++17 (GCC 7-32) TESTS 10 46 0
255819388 qwedc001 F April 9, 2024, 5:02 a.m. OK C++20 (GCC 13-64) TESTS 10 46 0
255818512 remain11 F April 9, 2024, 4:52 a.m. OK C++20 (GCC 13-64) TESTS 10 46 0
255818386 kizu F April 9, 2024, 4:51 a.m. OK C++20 (GCC 13-64) TESTS 10 46 0
255817662 kizu F April 9, 2024, 4:42 a.m. OK C++20 (GCC 13-64) TESTS 10 46 0
255815961 SunXiaoChuan F April 9, 2024, 4:21 a.m. OK C++20 (GCC 13-64) TESTS 10 46 0
255812610 Mayank_Bhakat F April 9, 2024, 3:39 a.m. OK C++20 (GCC 13-64) TESTS 10 46 0
255812349 Aldk F April 9, 2024, 3:36 a.m. OK C++20 (GCC 13-64) TESTS 10 46 0
255810796 QianSui F April 9, 2024, 3:15 a.m. OK C++20 (GCC 13-64) TESTS 10 46 0
255810554 Aurora0915 F April 9, 2024, 3:12 a.m. OK C++20 (GCC 13-64) TESTS 10 46 0
255809787 jackylova_fan_fan_fan F April 9, 2024, 3:04 a.m. OK C++20 (GCC 13-64) TESTS 10 46 0
255801287 Specter_TheUnchained F April 9, 2024, 12:53 a.m. OK Go TESTS 10 62 921600
255776609 Fanatikk F April 8, 2024, 6:57 p.m. OK Java 21 TESTS 10 249 0
255825268 amit_roy F April 9, 2024, 5:58 a.m. OK Java 21 TESTS 10 249 512000
255767867 lyongwolf F April 8, 2024, 5:49 p.m. OK Java 21 TESTS 10 249 512000
255803574 Zhanzhe_Lee F April 9, 2024, 1:31 a.m. OK Java 21 TESTS 10 249 716800
255808125 priyaroy3370 F April 9, 2024, 2:42 a.m. OK Java 21 TESTS 10 249 819200
255787309 BlizGale F April 8, 2024, 8:51 p.m. OK Java 21 TESTS 10 265 921600
255813279 HWJHWJ F April 9, 2024, 3:47 a.m. OK Java 21 TESTS 10 312 204800
255779083 chiragsingh876 F April 8, 2024, 7:21 p.m. OK Java 21 TESTS 10 359 1126400
255791090 Harsh_Agrawal_12 F April 8, 2024, 9:41 p.m. OK Java 21 TESTS 10 359 1228800
255780807 chiragsingh876 F April 8, 2024, 7:39 p.m. OK Java 21 TESTS 10 359 1331200
255779034 new__1 F April 8, 2024, 7:21 p.m. OK Java 8 TESTS 10 155 0
255768424 samy10127 F April 8, 2024, 5:53 p.m. OK Java 8 TESTS 10 187 0
255811878 neixinag F April 9, 2024, 3:29 a.m. OK Java 8 TESTS 10 234 0
255820422 jiminaseinen F April 9, 2024, 5:12 a.m. OK Java 8 TESTS 10 249 0
255815663 HardikG12 F April 9, 2024, 4:17 a.m. OK Java 8 TESTS 10 249 0
255802049 duyipeng F April 9, 2024, 1:06 a.m. OK Java 8 TESTS 10 296 0
255818973 NerfThis F April 9, 2024, 4:57 a.m. OK Java 8 TESTS 10 312 39833600
255768970 wat2 F April 8, 2024, 5:57 p.m. OK Java 8 TESTS 10 437 39628800
255775642 Kams7 F April 8, 2024, 6:48 p.m. OK PyPy 2 TESTS 10 249 3993600
255810012 smilences F April 9, 2024, 3:06 a.m. OK PyPy 3-64 TESTS 10 155 9625600
255804981 RobinFromTheHood F April 9, 2024, 1:56 a.m. OK PyPy 3-64 TESTS 10 156 6451200
255822562 helltractor F April 9, 2024, 5:33 a.m. OK PyPy 3-64 TESTS 10 156 8294400
255770381 iN_siDious F April 8, 2024, 6:07 p.m. OK PyPy 3-64 TESTS 10 171 9113600
255776804 DarkTemplarDrop F April 8, 2024, 6:59 p.m. OK PyPy 3-64 TESTS 10 171 9523200
255817877 Qian_Feng F April 9, 2024, 4:46 a.m. OK PyPy 3-64 TESTS 10 187 9523200
255775235 edgerunner F April 8, 2024, 6:45 p.m. OK PyPy 3-64 TESTS 10 202 6041600
255808610 JinYuManTang F April 9, 2024, 2:48 a.m. OK PyPy 3-64 TESTS 10 202 9830400
255815062 ankan2526 F April 9, 2024, 4:09 a.m. OK PyPy 3-64 TESTS 10 202 139980800
255790249 el_tunel F April 8, 2024, 9:28 p.m. OK PyPy 3-64 TESTS 10 218 9830400
255767007 OLOGY F April 8, 2024, 5:44 p.m. OK Python 2 TESTS 10 140 102400
255805026 enkeph F April 9, 2024, 1:57 a.m. OK Python 3 TESTS 10 109 0
255788405 Slata F April 8, 2024, 9:04 p.m. OK Python 3 TESTS 10 109 102400
255796458 Ptsh_368 F April 8, 2024, 11:18 p.m. OK Python 3 TESTS 10 124 0
255786532 avengers2405 F April 8, 2024, 8:41 p.m. OK Python 3 TESTS 10 124 0
255809555 winter_l F April 9, 2024, 3:01 a.m. OK Rust 2021 TESTS 10 77 0
255800999 tamuraup_wa F April 9, 2024, 12:48 a.m. OK Rust 2021 TESTS 10 156 68096000

remove filters

Back to search problems