Showing posts with label logical arcade. Show all posts

Monday, February 2, 2015

Bread And Water

No comments :
bread and water riddle
The unforgiving heat of the desert sun was unbearable. Nearing total exhaustion, Alek the Polish traveller stumbled ever onwards through the endless expanse of sand. His camel had fled, his water reserves were long exausted, and there was not even a lizard to catch for sustenance -- not that he would have had the energy to catch it in any case. All he had left with him were the clothes he wore, eight golden coins, and his need for food and water.

He collapsed, looked up and thought that the sun had had the better of even his eyes; he saw two bedouins walking towards him. Mirages, he thought. He shook his head and rubbed his eyes to clear it, but the bedouins were still there, getting closer. When they reached him, Alek weakly asked for water and some food, and promised he would repay them generously.

They introduced themselves as Azad and Mohammed. "Water," one of them said, "is free." As far as food was concerned, they would share with him, which consisted of bread only. Azad had three slices, and Mohammed had five. They put the slices together, split them in three equal parts, and each of them ate his portion quietly. When they finished their meal, Alek pulled out his eight golden coins, and set them before the bedouins, telling them to share them fairly. He thanked them for saving his life, promised to call them sometime, and with renewed energy continued his journey.
When the traveller was gone, the two bedouins looked at the eight golden coins for a little while, and then Mohammed moved his hand to grab five coins.

"Hold it there!" said Azad. "We will share them as good friends; four coins each!"

Mohammed was convinced he deserved five coins, but Azad would not agree, and the argument grew louder. Before the first punch was thrown, the Great Sage happened to be passing by on his camel. He enquired about the matter, which was quickly explained by the bedouins.

"Neither 5 - 3 nor 4 - 4 are fair," stated the Great Sage, before sharing his wisdom.

The bedouins got their fair share of the coins, and the Great Sage went on his way, satisfied that yet another problem had been resolved.

How much did each of the bedouins get?

Bread And Water Puzzle Solution

Each slice of bread was divided into 3 equal pieces, making a total of 24 pieces. These were then divided between the three men, 8 pieces each.

Mohammed had 5 slices, and so contributed 15 pieces. He ate 8 pieces himself, so 7 were eaten by Alek.

Azad had 3 slices, which contributed 9 pieces. Azad ate 8, leaving 1 piece for Alek.

Therefore, Mohammed gave 7 pieces of bread away, and Azad only gave 1 piece. So Mohammed deserves 7 gold coins and Azad only 1. If he were smarter or less greedy, Azad should have accepted Mohammed's initial offer of 5 - 3.

Sunday, October 5, 2014

Faulty Batches

No comments :
"This time," said the Treasury Minister, "I ditched those dodgy Europeans, and I have assigned the manufacture of our gold coins to five American companies. Look, they are all shining and beautiful, and they are all exactly the same!"

The secretary looked at the coins, weighed some of them, and cleared his throat. "Ahem, Sir. I would like to point out that here we have at least three different kinds of coin; they all look the same, but their weight is different. Would you please come close to the scale? This coin weights 10 grams, as it should, but this other one is 11 grams, while this one is only 9 grams. Obviously two of our manufacturing companies haven't done a good job."

Sad as he could have been, for having been tricked agin by other dodgy companies, the Minister managed to raise his head. "Well.. it's just a matter of finding the fauly ones using the trick that you've showed me, by using the scale only once..."

"Sir. Actually, this is a different problem altogether, we need to find two sources of errors, rather than just one. One batch is heavier, another is lighter. The method I used before will not be sufficient this time. But we can nevertheless find the two offending batches by using the scale once."

How did they manage to use the scale only once?



Notes:
  • You may assume that each batch is made of a large amount of coins (thousands, millions, up to you! :)
  • All coins of the same batch weight the same amount.
  • The storyline in this puzzle follows from the story in Faulty Batch. It is however NOT necessary to have previously read/solved that puzzle in order to solve this one, even though it may be preferable.

Faulty Batches Puzzle Solution

They had to weigh 1 coin from the 1st batch, 2 from the 2nd, 4 from the 3rd, 8 from the 4th, and 16 from the 5th one.

If all coins weighed 10 grams as they should, the scale would display 310 grams ((1 + 2 + 4 + 8 + 16) * 10). However, since one batch has 9 grams coins, and another 11 grams coins, then the total weight of this combination of coins will be:
Total Weight Number of
9g coins
Number of
11g coins
311 1 2
313 1 4
317 1 8
325 1 16
312 2 4
316 2 8
324 2 16
314 4 8
322 4 16
318 8 16
309 2 1
307 4 1
303 8 1
295 16 1
308 4 2
304 8 2
296 16 2
306 8 4
298 16 4
302 16 8

After seeing the solution to this puzzle, it is clear that it would be a lot easier to simply use the scales up to 5 times rather than go through all this, but where is the fun in that?