Five men were stuck in a desert island. The island was plentifully supplied with coconuts, fortunately, and they spent the first day gathering the coconuts, heaping them in a great pile.
That night, one of the men was sleepless at the thought that everyone would fight over the coconuts at daybreak. So he arose, crept to the pile, and counted out the coconuts. Except for one coconut, it was possible to divide the pile into five equal portions. He gave the extra coconut to the monkey (who was the only other living being on the island besides those five men), buried his share of the coconuts, then went back to a sound sleep leaving the rest again in a pile.
Then another man got up and stole to the pile with the same object in mind. Again there was one coconut left over. The second man gave the spare coconut to the monkey, buried (what he thought was) his fair share, and went back to sleep, again leaving the remaining coconuts in one pile.
One by one, the remaining men got up and did the same and everytime the monkey got his share of one coconut.
In the morning, the men divided whatever coconuts remained into five equal piles, each taking his share and saying nothing about the night just past.
What is the minimum number of coconuts the five men assembled on the first day, if in the Final Division:
(a)There was again one coconut left over and the men (as usual) gave it to the monkey.
(b) There was no coconut left over for the monkey.
4b - 1 = 625i - 5, so 4b = 625i - 4. So 4 divides 625i - 4, thus it divides i. So i = 4j for some j. Susbtituting that and cancelling yields:
b = 625j - 1
Taking that last value into 4a - 1 = 5b yields:
4a - 1 = 3125j - 5, which is 4a = 3125j - 4. So 4 divides 3125j - 4, thus it divides j. So j = 4k for some k. Subtituting that (and cancelling, of course) gives:
a = 3125k - 1
The last equation is x - 1 = 5a. Joining the last 2 equations we get:
x - 1 = 15625k - 5. So x = 15625k - 4
To minimize everything, we must take k to be the samllest integer. So k = 1. Now x = 15621. That's what the men collected the first day...
In summary:
The first man sees the 15621 coconuts, gives one to the monkey, and takes 3124, leaving 12496. So the second man gives one to the monkey and takes 2499 coconuts, leaving 9996. The third man gives one to the monkey and takes 1999, leaving 7996. The fourth one gives one to the monkey, takes 1599 and leaves 6396 behind. The fifth man gives one to the monkey and takes 1279, leaving 5116. Finally, on the next day, they give one to the monkey, and take 1023 each. In total, the guys have:
first man: 4147
second man: 3522
third man: 3022
fourth man: 2622
fifth man: 2302
monkey: 6
Sorry for making it toooooo long, and separating it into 2 parts (my browser didn't let me submit the whole thign together)
|
Posted by Fernando
on 2003-03-26 09:43:15 |