Difficulty understanding the problem


  • -1
    J

    I'm having difficulty understanding the problem. I hope someone can clarify for me. Thanks!

    Is it asking if, for a given n, there is at least one way for me to win? Or is it asking if there's a way for me to win such that it excludes any ways of the other player winning? An illustration of the difference is n=5. This is winnable by me or the other player, depending on the quality of the moves he makes. But it's not winnable exclusively by me based on some "ideal" first move. Contrast this with n=3. There is an ideal first move, where I remove 3, which completely prevents the other player from winning.


  • 0
    J

    Nevermind. I solved it. One-liner.

    To answer my question: the goal is to determine if, given a rock count, there's a series of ideal moves that I can make that preclude any winning options for the other player at any point in the game. I hope this answer helps others.


Log in to reply
 

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.