Puzzle: You have two container - one can contain exactly 3 litres of water and the other can contain exactly 5 litres of water. How many minimum steps will you take to get exactly 4 litres of water without using any other container? You can assume the availability of sufficient quantity of water.
Solution: Find below the steps:-
Step #1: fill the 5 litres container (3L - 0, 5L - 5)
Step #2: fill the 3 litres container with the filled 5 litres container (3L - 3, 5L - 2)
Step #3: empty the just filled 3 litres container (3L -0, 5L - 2)
Step #4: transfer the 2 litres of water left in 5 litres container into 3 litres container (3L - 2, 5L - 0)
Step #5: fill the 5 litres container (3L - 2, 5L - 5)
Step #6: fill the 3 litres container (having 2L currently) using just filled 5 litres container (3L - 3, 5L - 4)
So in a minimum of 6 steps you get exactly 4L of water in the 5 litres container.
No comments:
Post a Comment