# Suppose you have a 3 liter jug and a 5 liter jug (this could also be in gallons). The jugs have no measurement lines on them either. How could you measure exactly 4 liter using only those jugs and as much extra water as you need?

This question was actually asked in a popular movie – Die Hard With A Vengeance.

Try figuring this one out on your own before reading the answer. It should be clear that the goal is to end up with 4 liter in the 5 liter jug, since having 4 liters in the 3 liter jug is impossible.

## The answer, broken down in steps:

Step 1 : First, fill the 5 liter jug and then pour it into the 3 liter jug. The 5 liter jug now has only 2 liters left.

Step 2 : Next, empty out the 3 liter jug. Then, pour the 2 liters from the 5 liter jug to the 3 liter jug. So, now the 3 liter jug has 2 liters.

Step 3 : Fill the 5 liter jug again, and pour 1 liter into the 3 liter jug. Now, what’s left in the 5 liter jug? Well, exactly 4 liters! There’s your answer.

Subscribe to our newsletter for more free interview questions.

• Mahesh Pawar

OR….
step 1: u can pour water from 3 litre jug to 5 litre one time.Now 5 liter jug has 3 liter water .
Step 2:Again pour water from 3 liter jug to 5 liter jug .Now 5 liter will be full & 3 liter will have “1 liter water”.
Step 3: pour remaining 1 liter water from 3 liter jug to empty jug(The third jug or can use 5 liter jug after emptying it).
Step4: fill 3 liter jug again & pour all in empty jug. empty jug will exactly have 4 liter.