You are not logged in.
Three sailors and a monkey are shipwrecked on a desert island, where coconuts are the only available food. The men collect coconuts, but decide to wait until morning to divide the supply. However, once Bob and Carl are asleep, Mark arises, divides the pile of coconuts into three equal shares, has one left over, gives it to the monkey, hides his pile, and restacks the others. Later, Bob sneaks out of bed, divides the pile of coconuts into three equal shares, has one left over, gives it to the monkey, hides his pile, and restacks the remaining coconuts. Toward morning, Carl, too, arises, divides the pile of coconuts into three equal shares, has one left over, gives it to the monkey, hides his pile, and restacks the remaining coconuts. In the morning, the sailors meet and divide the pile of coconuts. Again, one coconut is left over for the monkey.
Find the least possible number of coconuts in the original pile, and then write a general formula for the problem (be sure to define your variables).
I know through guess-and-check that the answer is 79 coconuts, but I can't figure out the general equation.
Offline
Hi;
One way is:
With the constraint that x and y are both positive integers from which you can use Bezout's identity from the particular solution.
If you do not like math you might also want to look at this
http://www.experimentgarden.com/2009_07_01_archive.html
and see if you can adapt his reasoning to your problem and get 3^4 - 2 as the answer.
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline