Approach hintTry it first, then revealHide
If one pile holds more stones than all the others combined, the first player wins by always taking from it. Otherwise every stone gets removed, so the parity of the total decides.
More in Game Theory
| # | Problem | Platform | Difficulty | Open | 1st1st Visit | 2nd2nd Visit | RevRevise |
|---|---|---|---|---|---|---|---|
| 1 | Stone Game III | LeetCode | Hard | Solve Stone Game III on LeetCode (opens in a new tab) | |||
| 2 | 1-2-K Game | Codeforces | Medium 1700 | Solve 1-2-K Game on Codeforces (opens in a new tab) | |||
| 3 | Stoned Game | Codeforces | Hard 1800 | Solve Stoned Game on Codeforces (opens in a new tab) | |||
| 4 | A Lot of Games | Codeforces | Hard 1900 | Solve A Lot of Games on Codeforces (opens in a new tab) | |||
| 5 | GameGame | Codeforces | Hard 1900 | Solve GameGame on Codeforces (opens in a new tab) | |||
| 6 | Tree Tag | Codeforces | Hard 1900 | Solve Tree Tag on Codeforces (opens in a new tab) | |||
| 7 | Cat and Mouse | LeetCode | Hard | Solve Cat and Mouse on LeetCode (opens in a new tab) | |||
| 8 | Not a Nim Problem | Codeforces | Hard 2100 | Solve Not a Nim Problem on Codeforces (opens in a new tab) | |||
| 9 | Lieges of Legendre | Codeforces | Hard 2200 | Solve Lieges of Legendre on Codeforces (opens in a new tab) |