Five pirates are marooned on an island and spend the day collecting coconuts, intending to divide them up the next morning. One of the pirates decides to get more than his share. So, he gets up at night and finding that the coconuts they had collected do not divide by five unless one coconut is removed. So he gives one coconut to a monkey, removes 1/5 of the remaining hides them. Each pirate does this in turn, giving one to the monkey and hiding 1/5 of the rest. When they wake up, everyone notices the diminished pile but since they all stole, no one says anything. So, they give one to the monkey and take 1/5 th of the rest each. What is the least number of coconuts for which this is possible?
Solution: The easiest way to solve this puzzle is to use a trick. We start with - 4 coconuts. Each pirate, when he wakes up at night and takes some of the coconuts give one to the monkey and then keeps 1/5. With - 4 coconut, giving one to the monkey leaves - 5 coconuts. Take away 1/5 and we are back to - 4. Thus - 4 is a fixed point of the process. Since there were 6 divisions by five after giving one to the monkey, the minimum required is 56-4 = 15,621.
Let us see how this works:
· First pirate: Gives one to monkey leaving 15,620 coconuts. Keeps 1/5 th and leaves 4/5 th = 12,496 coconuts.
· Second pirate: Gives one to monkey leaving 12,495 coconuts. Keeps 1/5 th and leaves 4/5 th = 9,996 coconuts.
· Third pirate: Gives one to monkey leaving 9,995 coconuts. Keeps 1/5 th and leaves 4/5 th = 7,996 coconuts.
· Fourth pirate: Gives one to monkey leaving 7,995 coconuts. Keeps 1/5 th and leaves 4/5 th = 6,396 coconuts.
· Fifth pirate: Gives one to monkey leaving 6,395 coconuts. Keeps 1/5 th and leaves 4/5 th = 5,116 coconuts.
· Morning: Give one to monkey leaving 5,115 coconuts. Divide equally so each gets 1023 coconuts in the last division.
It is said that Paul Dirac, the physicist, on being told the puzzle, immediately came up with the number -4 as the fixed point of the problem, possibly because he invented the concept of “holes” or “negative particles” (also called anti-particles) in his formulation of the famous Dirac equation for electrons.
The general solution with n pirates is that the minimum number of coconuts required is nn+1 – n + 1.