Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Today our professor presented us with a puzzle of interest called The 'eating apple' problem (I have no idea what is it called formally though). The rules are

  • There are three compartments, in which each compartment contains 3, 5, and 7 apples respectively.
  • Two players, or 'eaters', will eat n apples in turns, until all apples are eaten. (n>0, n not necessarily 1)
  • The last player to empty the compartments will be declared the loser.
  • Each player can eat from at most one compartment at a time.

After trial and error with my friends, I have discovered that the person who starts the game will have an advantage, if not even a total dominance over the other player, but how can I prove this? As a cs student, I'm not a math geek at all, so a little help to where I can start would be appreciated.

share|improve this question
    
Have you tried thinking about what would happen if you had one compartment? Then two? Then maybe one apple in the third compartment etc –  Mark Bennet Apr 10 '12 at 6:12
    
Related: math.stackexchange.com/questions/52130/the-game-of-nim and math.stackexchange.com/questions/33468/a-nim-game-variant. The first is not exact dupe, but can be considered minor variant, I suppose. The second is just related. –  Aryabhata Apr 10 '12 at 6:16
add comment

1 Answer

up vote 2 down vote accepted

This is the classic game/variant of NIM. The wiki has a good description on the winning strategies.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.