There is a camel which can carry max 1000 bananas at a time and eat 1 banana for every one kilometer. There 1000 km desert and you need to move this 3000 bananas across the desert. How many maximum bananas you can transfer the other end of desert.
if you think in strait way the max bananas will be 0.
but there is a solution:
lets talk about every km. you would like to transfer 1000 bananas 1 km. Now camel will take 1000 bananas and come back and again take 1000 bananas and come back and take 1000 bananas again. so there is total five trips to transfer 3000 banana 1 km. for this transfer camel will eat 5 bananas.
camel will take 5 trips until there is 2000 bananas so lets find out how main km camel will move until 2000 bananas left.
1000/5 =200 km
now for 2000 bananas camel will make 3 trips, so lets find out how many km camel will move until 1000 bananas left.
1000/3 = 333 km
so now there is only 1000 banana left and camel have moved to 200+333 = 533 km
left distance = 1000-533 = 467 km
so at end left bananas = 1000 - 467 = 533 bananas
there can be another solution when camel will not eat any banana while coming back and not carrying the bananas. in that can solution will be 833 bananas
No comments:
Post a Comment