Problem 3320 · Hard

Count The Number of Winning Sequences

Track Bob's last move and the running score difference in a DP, skipping any move that repeats the previous round.

Open the interactive visualisation