Search
⌘K

Leetcode 1406. Stone Game III

Two players alternately take 1–3 stones from the front of an array of integers (which may be negative), each accumulating the values they take. Determine whether Alice, Bob, or a Tie occurs under optimal play — the core challenge is computing the optimal score difference using DP/minimax over array suffixes (n up to 5·10^4).


Question Timeline

See when this question was last asked and where, including any notes left by other candidates.

Comments

Your account is free and you can post anonymously if you choose.