← All problemsSign in

Vinish and Bharath Play a Game

Vinish and Bharath were getting bored in their class,so they decided to play a game. The game is as follows,initially there is a single array containing N white cells.Both take turns alternately, and in each turn a player can mark any one cell of the array as black.They define a block of 3 consecutive black cells as a streak.The first one to create a streak wins and is declared as the winner. Bha

HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17

CodeSearch Tutor

Hints, not spoilers — it won’t hand over the full solution unless you insist.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start