## Interview Question

Business Analyst Interview

-Arlington, VA

Capital One## You have 3000 bananas at point A, which is 1000 feet removed from point B. You must move as many bananas to point B, but you can only carry 1000 bananas at any time, and traveling 1 feet requires you to eat 1 banana. You can drop off bananas at any point between A and B, and pick them up later.

AnswerAdd Tags

## Interview Answers

27 Answers

▲

4

▼

It's not 500. Not sure if correct but I calc 666.

John on

▲

2

▼

Hey G It goes like this 1000-2x+1000-2x+1000-x=2000 ( equate it to 2000 because after this u will wont need to go back third time as the maximum u can carry will be over in two time) x=200 (first stop point @ 200 feet) 1000-2y+1000-y=1000 ( equate it to 1000 because after this u will wont need to go back second time as the maximum u can carry will be over once y=333 (second stop point @ 533 feet) so you can move the remaining 1000 distance in (1000-533)=533 to Point B. So 533 bananas left

Nandy on

▲

1

▼

How did you arrive at 666?

Grace on

▲

1

▼

Not very clear formulation of problem . I move V (in thousand) bananas on L feets., what I get in point L 1.V-L/V Or 2.(V-L) In first case I spend 1/V moving on 1 feet, but in second energy do not depend of load.

victor01 on

▲

1

▼

Sorry for the fat fingers in my answers! I ate too many bananas and was feeling ill, lol

Anonymous on

▲

0

▼

Second apology. Somehow seems as if my response sequence got messed up. I'll try this again!

Anonymous on

▲

1

▼

I must eat a banana whether traveling to or from point A. I take 1000 and walk 333 feet I arrive with 667 and leave 334 of them I get back to point A empty handed and grab another 1000. At 333 feet, I take 333 of those I left the first time, resuming my journey with 1000 bananas. I walk to the 666 feet mark arriving with 667. I leave 2 and head back with 665 in my possession. I pick up the one I left at the 333 point mark and make it back to point A empty handed. The last thousand is enough fuel to get me from A to B, so I arrive at point B with the two bananas I had left at 666 feet. The answer is 2

Anonymous on

▲

1

▼

The answer can be googled, they offer a generalized form. For this particular example it is 533

OP on

▲

0

▼

3000. Since the direction of the distance between point A and point B is not specified, we can assume point A is at a higher elevation than point B. We can then either 1) slide the bananas down the slope from point A to point B if we assume the their is a slope with a low enough coefficient of friction, or 2) assume that Point A is directly above point B and simply drop the bananas. Since in both scenarios we do not have to move, there is no need to eat any bananas. (Note: for the second scenario, the problem does not specify the condition the bananas should be in when they arrive at point B.)

Anonymous on

▲

0

▼

Hey ltss587ATgmailDOTcom - I understand how you got to 1000-2x+1000-2x+1000-x (3000-5x) which is effectively number of banas left at Point X. Why did you equate it to 2000? what is the rationale to it? Also how did you get the second equation? 1000-2y+1000-y=1000 Wei - In your equation, though it makes sense, but u didnot go back the third time to pick up the 1000 bananas. At this time, y-3x=0., you still have a 1000 bananas left? Could you please explan. I really appreciate it.

G on

▲

2

▼

It should be around 666 bananas.

Annie on

▲

0

▼

how do you mathematically formulate it? I mean I see how it's 500 from intuition. But, if I were to approach the problem from a purely mathematical way, how would I formulate it?

priyanshu on

▲

0

▼

@Shilpa, Could you share what you found? Thanks!

Max on

▲

2

▼

sorry guys its 833 bananas You have to do it a foot at at time to max out You'll have to carry 3 loads until you eat 1000 bananas so 3x = 1000 or x = 333 ft. next you have to carry 2 loads until you eat the next 1000 bananas so 2x = 1000 or x = 500 ft. Now you have exactly 1000 bananas left so only one load fo the remaining 167 feet this gives you 833 bananas left.

Skaaary on

▲

1

▼

It is 333 bananas!!!

Seema K on

▲

1

▼

833 is the maximum left and best explanation. Do it on a number line. Maximize each load and trip. The second step must be 2 trips closest to the goal ending with 1000 bananas because there be one final trip at maximum load the shortest distance. So stops at 333+500+167 gets the most product moved at least cost. Logistics.

clg on

▲

2

▼

Technically this isn't really asking anything.

Matt on

▲

0

▼

Technically you don't have to eat any bananas. If you move them less than a foot each time, you don't have to eat any bananas.

Micah on

▲

2

▼

1000-2x+1000-2x+1000-x=2000 x=200 (first stop point @ 200 feet) 1000-2y+1000-y=1000 y=333 (second stop point @ 533 feet) so you can move 1000-(1000-533)=533 to Point B.

ltss587ATgmailDOTcom on

▲

0

▼

Sorry my Error not 1/v but V and not (V-L/V) but (V-V*L)

victor01 on

▲

1

▼

500? How? Could you pls explain?

Shilpa on

▲

0

▼

833 is correct. Starting at 1000 feet mark. Carry 1000 bananas drop 999 at 999 foot mark. Go back and bring 2*1000 similar way and drop at 999 ft. Now you have 3*999 bananas at 999 feet. Keep doing this until 3*x exceeds 1000. You are now at 666 foot mark with 1998 (3000-334*3) bananas. Now do two trips and drop bananas at each foot traveled. At 177 (833) foot mark you will have 1000 bananas. Now you will loose 177 bananas to end

Anonymous on

▲

0

▼

Incomplete question but this is making the presumption that the answer required is 'what is the largest number of bananas I get get to point B'? Te answer is 2 You must eat one banana per foot traveled. Whether forward or backwards, a foot is still a foot, so a banana must be eaten. If I take 1000 bananas and drop 334 of them off after 333 feet, I will have just enough to get back to point A. I grab another 1000. I walk 333 feet, arriving with 667 bananas. I pick up 333 of those I left the first time, leaving one, and walk another 333 feet. I reach the 666 feet mark with 667 in my possession. I leave two there. One my way back, I must pick up the remaining banana from the 333 foot mark in order to get back to point A. (665+1) I pick up the remaking thousand. At 666 feet, I have 334 left. I pick up the 2 that I left there, then eat the 334 necessary for me to reach point B. I have 2 left I grab the remaining 1000. I reach the 666 mark with 334 bananas. I take the one I left there. I walk 334 feet, arriving at point B with a single banana

Anonymous on

▲

3

▼

Don't worry it...got it

Shilpa on

▲

0

▼

3000, pickup 1000 bananas and walk 1/2 feet, go back get another 1000 and put them @ 1/2 ft location and then get the rest bunch.

og on

▲

1

▼

let us say you move x feet before you drop your bananas and then go back to point A, and let's say you pick 1000 bananas first time. You eat x bananas when you get to point x, and since you need go back to Point A, you will keep another x bananas, then you drop 1000-2x bananas at point X, next time suppose you pick y bananas, when you get to point X, you will eat y-x bananas, and pick former dropped 1000-2x bananas, all these bananas add up to 1000, so we got y-3x+1000=1000, that's y-3x=0. Since we can pick max 1000 bananas, so max y is 1000, x is 333, that is say, we can go as far as 333 feet and then we must go back. since after we get to point b and don't have any more bananas for us to go back to point A, seems 333 is the answer

Wei on

▲

7

▼

500 bananas

Jordan on

## Add Answers or Comments

To comment on this, Sign In or Sign Up.