This week's book giveaway is in the Big Data forum. We're giving away four copies of Elasticsearch in Action and have Radu Gheorghe & Matthew Lee Hinman on-line! See this thread for details.

Mary has a full 8-quart container (Container A) of peanut oil. She wants to share half of the oil with her sister. She has another 2 empty containers (B and C) with the capacities: 5 quarts and 3 quarts. Can you, without weighing the containers, put 4 quarts of oil in container B with the least number of steps for her sister?

(1) Take out 3 quarts of oil from A into C. A has 5 quarts left now. (2) Transfer 3 quarts from C to B. Now B has 3, A has 5 and C has zero. (3) Take out Another 3 quarts from A into C. A=2, B=3, and C=3 now. (4) Transfer from C to B only till B is full. A=2, B=5 and C=1 ((3-2)) now. (5) Empty B in A now. A=7, B=0 and C=1; (6) Put C in B. A=7, B=1 and C=0; (7) Take out 3 quarts from A to C. A=4, B=1 and C=3. (8) Transfer C to B. A=4, B=4 and C=0.

Yes Thats right. Now this question should be closed. Rakesh do you have any query regarding this question. Please ask to Hat Waale. otherwise give your confirmation.

The Best way to predict your future is to create it - Every great individual common man

Originally posted by Ankur Sharma: Dear Hat Waale/ Joshi.

Yes Thats right. Now this question should be closed. Rakesh do you have any query regarding this question. Please ask to Hat Waale. otherwise give your confirmation.

Ankur,

I have a proper name - Manish. Please use that and do not make fun of my surname, though you may not have inteded it that way.

I have a proper name - Manish. Please use that and do not make fun of my surname, though you may not have inteded it that way.

- Manish

---

Manish I am really sorry for that, if you hurt but beleive me that was not intended that was totally a typo mistake........ pls don't get hurt... I extremly apolozise for this typo mistake.........

I hope now onwards you don't have any wrong spirit for me...