Posts

Showing posts with the label capacity

Crossing The Stone Bridge : Puzzle

Three people, Ann, Ben and Jen want to cross a river from left bank to right bank. Another three people, Tim, Jim and Kim want to cross the same river from right bank to left bank.

However, there is no boat but only 1 stone bridge consisting of just 7 big stones(not tied to each other), each of which can hold only 1 person at a time. All these people have a limited jumping capacity, so that they can only jump to the stone immediately next to them if it is empty.

 
Now, all of these people are quite arrogant and so will never turn back once they have begun their journey. That is, they can only move forward in the direction of their destination. They are also quite selfish and will not help anybody traveling in the same direction as themselves.


But they are also practical and know that they will not be able to cross without helping each other. Each of them is willing to help a person coming from opposite direction so that they can get a path for their own journey ahead. With this help, a person can jump two stones at a time, such that if, say, Ann and Tim are occupying two adjacent stones and the stone next to Tim on the other side is empty, then Tim will help Ann in directly jumping to that stone, and vice versa.


Now initially the 6 people are lined up on the 7 stones from left to right as follows:


Ann Ben Jen emp Tim Jim Kim
(where emp stands for empty stone).


Your job is to find how they will cross over the stones such that they are finally lined up as follows:


Tim Jim Kim emp Ann Ben Jen


Now, find out the shortest step-wise procedure, assuming that Tim moves first.


Crossing The Stone Bridge : Puzzle


THIS is the shortest way! 

Crossing The Stone Bridge Puzzle : Solution


What was the puzzle?

Initially the 6 people are lined up on the 7 stones from left to right as follows:
Ann Ben Jen EMP Tim Jim Kim
(where EMP stands for empty stone).


Step 1: Tim jumps to occupy the empty stone.

Ann Ben Jen Tim EMP Jim Kim

Step 2: Tim helps Jen in occupying the newly emptied stone between him and Jim. 


Ann Ben EMP Tim Jen Jim Kim
 
Step 3: Ben occupies the stone emptied by Jen.

Ann EMP Ben Tim Jen Jim Kim

Step 4: Ben helps Tim in occupying the newly emptied stone. 

Ann Tim Ben EMP Jen Jim Kim

Step 5: Jen helps Jim in occupying the empty stone. 

Ann Tim Ben Jim Jen EMP Kim

Step 6: Kim occupies the stone emptied by Jim. 

Ann Tim Ben Jim Jen Kim EMP

Step 7: Kim helps Jen in occupying the stone vacated by her. 

Ann Tim Ben Jim EMP Kim Jen
  
Step 8: Jim helps Ben in occupying the stone vacated by Jen. 

Ann Tim EMP Jim Ben Kim Jen

Step 9: Tim helps Ann in occupying the empty stone.


EMP Tim Ann Jim Ben Kim Jen

Step 10: Tim jumps to the stone emptied by Ann.

Tim EMP Ann Jim Ben Kim Jen

Step 11: Ann helps Jim in occupying the stone vacated by Tim.

Tim Jim Ann EMP Ben Kim Jen

Step 12: Ben helps Kim in occupying the stone vacated by Jim. 

Tim Jim Ann Kim Ben EMP Jen

Step 13: Ben occupies the empty stone.


Tim Jim Ann Kim EMP Ben Jen

Step 14: Kim helps Ann in occupying the stone emptied by Ben. 

Tim Jim EMP Kim Ann Ben Jen

Step 15: Kim jumps to the stone emptied by Ann.

Tim Jim Kim EMP Ann Ben Jen

This is exactly what we wanted!

Crossing The Stone Bridge Puzzle : Solution
 

"Go The Distance"

There are 50 bikes with a tank that has the capacity to go 100 km. Using these 50 bikes, what is the maximum distance that you can go? 


"Go The Distance"



Here is the maximum distance calculation!

Maximizing The Distance!


What was the challenge?
 
Remember, there are 50 bikes, each with a tank that has the capacity to go 100 kms. 

-----------------------------------------------------------------------------------------------

SOLUTION 1 : 

Any body can think that these 50 bikes together can travel 50 x 100 = 5000 km. But this is not true in the case as all bikes will be starting from the same point. And we need to find how far we can we go from that point. 

-----------------------------------------------------------------------------------------------

SOLUTION 2 : 

Just launch all 50 bikes altogether from some starting point and go the distance of only 100 km with tanks of all bikes empty in the end.

-----------------------------------------------------------------------------------------------

SOLUTION 3 : 

1. Take all 50 bikes to 50 km so that tank of each is at half.

2. Pour fuels of 25 bikes (half filled) into other 25 bikes so that their tanks are full.

3. Now, move these 25 bikes to another 50 km so that again their tanks are at half.

4. Pour fuel of 12 bikes into other 12 so that we have 12 bikes with full fuel tank. Leave 1 bike with half filled fuel tank and repeat above.

So for every 50 km distance, half of bikes are eliminated as - 

50 ---> 25 ---> 12 ---> 6 ---> 3 ---> 1

The last bike left with it's tank full can go 100 km. So. the total distance that can be traveled in the case is 5 x 50 + 100 = 350 km. 

However, we have wasted 1/2 fuel each whenever odd number of bikes are left i.e. at 25 and at 3. 

-----------------------------------------------------------------------------------------------

Maximizing The Distance!
 

SOLUTION 4 :

Let's optimize little further so that the 1/2 fuel is not wasted whenever odd bikes are left.


1. Take all 50 bikes to 50 km so that tank of each is at half.

2. Pour fuels of 25 bikes (half filled) into other 25 bikes so that their tanks are full.

3. Now take these 25 bikes to another 20 km using 1/5th (20/100) fuel of each. 

4. Make 5 groups of 5 bikes each. From each group, use 4/5th fuel of 1 bike to fill tank 1/5th emptied tanks of other 4 bikes.

5. Leave bike with empty tank and take 20 bikes to next 50 km. And again after 50 km, pour fuel of 10 bikes into other 10 to eliminate 10.

6. After moving 10 bike for another 50 km, again pour fuel of 5 bikes into another 5.

7. Now take these 5 bikes to another 20 km using 1/5th (20/100) fuel of each.

8. Use 4/5th fuel of 1 bike to fill tank 1/5th emptied tanks of other 4 bikes. 

9. Now these 4 bikes again taken to another 50 km where 2 more are eliminated by taking half of their fuel to fill tanks of other 2.

10. After taking those 2 bikes for another 50 km distance, 1 can be eliminated by taking away it's half fuel to fill up the tank of other bike.

11. The last bike can now go another 100 km distance as it's tanks is full.

To summarize,

50 ---50km---> 25 ---20km---> 20 ---50km---> 10 ---50km--- > 5 ---20km--- > 4 ---50km ---> 

--->2 ---50km---> 1 ---100km ---||

Total distance that can be traveled = 5 x 50 + 2 x 20 + 100 = 390 km.  

-----------------------------------------------------------------------------------------------

SOLUTION 5 : 

Now we have got the idea from SOLUTION 4 how to maximize the distance further.

Instead of waiting for tanks to be at half or 4/5th we should empty the tank of 1 bike into others at the point where that bike has sufficient fuel for this process.

For example, to have 49/50th fuel in tank of 1 bike at some point, all bikes need to be taken so that 1/50th of each is used up. Since the bike goes 100 km with full tank, with 1/50th fuel it can go 100 x 1/50 = 2km distance.

In short, after 2km distance 49/50th fuel of 1 bike can be used to fill 1/50th empty tanks of other 49 bikes. Now, that 1 bike with empty tank can be left there.

For next phase, we have, 49 bikes. Now, after using up another 1/49th fuel for another distance of (1/49) x 100 = 100/49 km, the 48/49th fuel left in any one bike can fill up the tanks of other 48 bikes (each with 1/49th part is empty). Then, these 48 bikes can be taken for the next phase.

Now, again after consuming 1/48 fuel for another distance of 100/48km, 47/48th of fuel from 1 bike can be used to fill tanks of other 47 bikes (each bike with 1/48th tank empty after traveling 100/48km). So, now 47 bikes can be taken for the next phase.

This way, we are making sure that at each phase 1 bike uses it's all fuel to make tanks of other full.

Repeating this process, till 1 bike left which can go further 100km with full tank.

So the total distance that can be covered is - 

100/50 + 100/49 + 100/48 +.................100/1 = 449.92 km.

And this is the maximum distance that we can go with 50 bikes.


-----------------------------------------------------------------------------------------------


Follow me on Blogarama