Puzzling Asked by user88 on May 22, 2021
A somewhat well-known puzzle is described as such:
You have a pile of 3,000 bananas. You wish to transport them to a place 1,000 miles away on the back of a camel; however, the camel can only carry a maximum of 1,000 bananas, and will eat one banana every mile it travels (and will not go anywhere if it does not have any bananas). However, you can load and unload as many bananas as you want anywhere. What is the most bananas you can bring over to your destination?
Obviously you can’t just load up 1,000 bananas and go, because the camel will have eaten them all by the time you get there.
I’d never figured out the answer by myself before. Does anybody have any insights into how to solve this problem and other problems like it?
Solution for $n$ bananas, where $n$ is the number of bananas you own, and $c$ is the number of bananas the camel can carry:
This is because, if the camel moves the bananas 1 mile at a time, he needs to make two trips for each load beyond his current capacity.
Define $t = lfloorfrac{n}{c}rfloor$ Therefore, the total number of miles the camel can reach is:
In particular, plugging in the given $n = 3000$ and $c = 1000$, we have that the camel can travel
To figure out how many bananas remain for a given distance,
For the first $1000$ miles, this number is just the distance beyond the total capacity:
Correct answer by durron597 on May 22, 2021
First of all, the brute-force approach does not work. If the Camel starts by picking up the 1000 bananas and try to reach point B, then he will eat up all the 1000 bananas on the way and there will be no bananas left for him to return to point A.
So we have to take an approach that the Camel drops the bananas in between and then returns to point A to pick up bananas again.
<---p1---><--------p2-----><-----p3---->
A---------------------------------------->B
-----> ------> -------->
<----- <------
-----> ------>
<-----
----->
Since there are 3000 bananas and the Camel can only carry 1000 bananas, he will have to make 3 trips to carry them all to any point in between.
When bananas are reduced to 2000 then the Camel can shift them to another point in 2 trips and when the number of bananas left are <= 1000, then he should not return and only move forward.
In the first part, P1, to shift the bananas by 1Km, the Camel will have to
Note: After point 5 the Camel does not need to return to point A again.
So to shift 3000 bananas by 1km, the Camel will eat up 5 bananas.
After moving to 200 km the Camel would have eaten up 1000 bananas and is now left with 2000 bananas.
Hence the length of part P1 is 200 Km.
Now in the Part P2, the Camel needs to do the following to shift the Bananas by 1km.
Note: After point 3 the Camel does not need to return to the starting point of P2.
So to shift 2000 bananas by 1km, the Camel will eat up 3 bananas.
After moving to 333 km the camel would have eaten up 1000 bananas and is now left with the last 1000 bananas.
Because it is a multiple of 3, after 333 times there is 1001 bananas left. Therefore, the camel must take 1000 bananas and then take 1 back with him to pick up the last banana, leaving him with 999 bananas. This would leave the camel at 334 km + 200 km, so the merchant only needs to travel 466 km, eating 1 banana for every km.
999 bananas - 466 bananas for each remaining km equals 533 bananas left at point B. Therefore, the merchant has 533 bananas to sell at point B.
Answered by skateboard34 on May 22, 2021
While the amount of bananas is larger than 2000, the camel will have to make 5 trips to shift them. At a cost of 1 banana per mile, this will cost 5 bananas per mile in total.
While the amount of bananas is larger than 1000, it takes 3 trips to shift them, so a total cost of 3 bananas per mile.
For the final stretch, it just takes a single banana per mile.
So at 5 bananas/mile you're down to 2000 bananas after 200 miles. Your total mileage then improves to 3 bananas/mile for the next 333 miles. After that, you're on the home stretch and move at 1 banana/mile for the remaining 467 miles (after which you'll have 533 bananas left).
A few things to note:
Answered by SQB on May 22, 2021
First leg of the journey:
Second leg, starting with mile 200:
Third leg of the journey:
You're left with 999-465 = 534 bananas.
Answered by SF. on May 22, 2021
I have a solution that has a better result than 534. I'm not sure it is the best solution.
Answered by duckman1611 on May 22, 2021
This is the best answer that does not require stopping every mile. Take
go
and drop off
Go back and repeat 2 more times. Now you are on mile
Go back and repeat. Now you are on mile
Answered by Martin on May 22, 2021
Load up camel with 1000 bananas. Travel 500 miles, leaving 500 bananas. Dump them there.
Do same trip again and leave 500 bananas at 500 mile mark.
Do same trip again and pick up one of the 500 banana piles when you hit the 500 mile mark. Now you are at 1000 again.
at 750 mile mark, drop your (now 750) bananas
Go back to mile 500, pick up your 500 bananas
Go to mile 750, and now you have 250 left
Pick up your 750 that you previously left
Now you have 1000 at mile 750
Walk the remaining 250 miles, leaving 750
Eat one for yourself and market the remaining 749 bananas.
749! Woo Hoo!
***Edit: I was basing mine off 538's recent Riddler, which says that the camel can travel w/o bananas as long as he doesn't sniff any bananas. So, whoops!
http://fivethirtyeight.com/features/how-many-bananas-does-it-take-to-lead-a-camel-to-market/
Answered by Phil Wells on May 22, 2021
Here is my solution, where camel arrives with 500 bananas:
Now, since the right answer is 534, the question is: where did I lose 34 bananas?
Answered by beetoom on May 22, 2021
You will made 7 loads, 3 unloads and 2 come backs.
Answered by Виктор Хорошилов on May 22, 2021
The traditional text of the problem is that the camel will eat 1 banana per mile if there is banana to eat. In this case...
Answered by jorge sampaio on May 22, 2021
Short and Concise solution,
Finally,
Answered by Saurav on May 22, 2021
to move 3000 bananas by 1 km, camel consumes 5 bananas which with five trips. so not when number of bananas are less than or equal to 2000 the trips required is 3. so to consume 1000 bananas 5x = 1000 move 3000 bananas for x=200 miles ( 5 trips). we are left with 2000 bananas.
now we have 2000 bananas and we can move bananas in 3 trips
3x =1000 move 2000 bananas for x=333 miles. we are left with 1000 bananas again.
now total distance traveled is 533 miles and left with 467 miles. we are left with 1000 bananas. camel can take these bananas in 1 trip. so 1000-467=533
Answered by user64643 on May 22, 2021
or
1 mile cost you 5 bananas or set up as a ratio - miles:bananas or 1:5.
Subtract 1000 bananas off the top because that's the most your camel can carry on the last load. Use the 2000 bananas to make a ratio equivalent to 1:5 or 1/5 = x/2000 x = 400 miles.
So if you repeat steps 1 - 3 till you only have 1000 bananas left, you will have covered 400 miles. Now you have 600 miles to go with 1000 bananas. You have 400 bananas to sell, unless you want to give your camel a treat.
Answered by user69912 on May 22, 2021
$533.(3)$
Let's do it as follows: Last span will be $x$ miles, and final answer is $1000-x$ bananas delivered. Next to last span will be $y$ miles, we would do best if each ride starts with 1000, i.e. $2000 -3y = 1000$ should hold to get to 1000 left for the last span. Hence $y = frac{1000}{3}$.
Now to get to 2000 from 3000 we will need 3 trips on path of length $z$, doing it optimally (starting with 1000 each trip), gets us to $3000-5z = 2000$, i.e. $z = frac{1000}{5} = 200$.
Answered by az20019 on May 22, 2021
Its pretty sure that, If the camel takes all the 1000 bananas at once to the end point,he would be left with 0 bananas at the end. So, there needs to some Intermediate Points that are in between O km and 1000 km.
So, to prove my point, Let us assume 4 points.
let's called point A------>Beginning Point point B------> End Point point Q------>First Intermediate Point point W------>Second Intermediate Point
3000 2000 1001 533
<------5X----------> <----3Y-----> <------------Z--------------------->
A--------------------Q-------------W------------------------------------B
If we take 1000 bananas at once to 1km,then there will be 3 trips forward, and 2 trips backward, so , there will be a total of 5 trips.
A<----------5x---->Q so, When we take 1000 bananas, we are only left with 600 bananas and similarly for the other one, but for the last one, there will be only 1 forward trip and so, its a total of 5 trips. Let's prove that with a simple equation,
3000-5X=2000 X=200 So, Point Q is 200km away from the begining.
Now, we are only left with 2000 bananas, and taking it to W, As we are only left with 2000 bananas, we can make a maximum of 2 trips forward, and 1 trip backward.
Q<-----3Y------>W It can be understood as we have only 2000 bananas left, and the camel can take 1000 bananas a time.
Let's find the distance with the Equation, 2000-3Y=1000 So, Y=333. But as the Camel is eating 1 banana per km,so, it can't be in fraction, thus, Y=333 As we reduced the term, so, will increase 1 banana,i.e, 1000+1=1001.
Again,there will only be 1 last trip, with the remaining distance, 1000-200-333=467. So, Remaining Distance=467. And 1000-467=533
Thus, total Bananas reached at destination=533.
Answer->533
Answered by Zenith Peterburg on May 22, 2021
Get help from others!
Recent Answers
Recent Questions
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP