The Dink Network

Two interesting puzzles

December 29th 2006, 02:42 AM
pq_skull.gif
dinkme
Peasant He/Him India
 
Hey guys, I have a couple interesting puzzles for you. Use your brain and try to solve them. The first one is the easier of the two. When you ultimately accept defeat, I'll post the solution. Post back if I have not made the puzzles clear for further explanation with examples.

The first one goes like this:

1. There are three preachers and three cannibals on a river bank. They want to cross the river and there is a boat that has a capacity to carry two people at a time. The gist is that, if the number of cannibals is greater then the number of preachers, the cannibals will eat away the preacher. Suggest a way in which all can safely cross the river. Moreover someone needs to row the boat back to the shore, it will not come back by itself for the second trip, so keep that in mind.

The second one goes like this:

2. There are 23 prisoners and a warden. There is an empty room that has two switches that can be turned ON or OFF and do nothing other than that. The warden says that each day he will pick a random prisoner who will go to the room and turn one of the switches ON if it is OFF, or will turn it OFF if it is ON. The warden suggests that if they are able to tell at the right moment: "Now all the prisoners have been to the room", he will free them all, but if they tell them this when everybody has not been to the room then he will hand them over to the crocodiles. They have been allowed to meet once before this process begins to plan their course of action and decide how they will estimate when all prisoners have been to the room. After this meeting they will be kept in seperate cells and will not be allowed to talk to each other. Each day, a random prisoner would go to the room and turn the switches On or OFF, as mentioned earlier. Moreover, the warden can pick the same person simultaneously but not more than 3 times.
Suggest a plan using the switches to free the prisoners.

I hope you tear your hair out trying to solve these. HEHE
December 29th 2006, 03:26 AM
goblinm.gif
One solution to the first puzzle is as follows:
Start: PPPCCC|
CC -> : PPPC|CC
<- C : PPPCC|C
CC -> : PPP|CCC
<- C : PPPC|CC
PP -> : PC|PPCC
<- PC : PPCC|PC (the tricky step)
PP -> : CC|PPPC
<- C : CCC|PPP
CC -> : C|PPPCC
<- C : CC|PPPC
CC -> : |PPPCCC
December 29th 2006, 03:36 AM
goblinm.gif
What are the intial positions of the switches?
December 29th 2006, 03:48 AM
knightg.gif
cypry
Peasant He/Him Romania
Chop your own wood, and it will warm you twice. 
I read the second puzzle before, but i couldn't find a solution. The initial position of the switches is random.
December 29th 2006, 05:01 AM
pq_skull.gif
dinkme
Peasant He/Him India
 
Good work, you got the first one and yeah the two switches are in random position.
December 29th 2006, 09:06 AM
custom_magicman.gif
magicman
Peasant They/Them Netherlands duck
Mmmm, pizza. 
I don't think you meant "simultaneously" in the last puzzle... It means "at the same time". If two things happen simultaneously, then they happen at the same time.

If you meant that every prisoner can be chosen a max of 3 times during the whole process, it's easy (using the pidgeon hole principle).
If you mean that one prisoner can be chosen any amount of of times, as long as it's broken up in series of three, nothing will stop the warden from choosing (1,2,1,2,1,2,1,2,1,2,1,2... etc), so there's not always a solution.

So, assuming there's an all-time maximum of 3, and that really every day a prisoner will be chosen, then every prisoner has been chosen three times after 23*3 = 69 days. You can reduce this to 67 days once you realise the last two have to have gone before. This upper bound still holds when the prisoners can't count the days.

Now, finding the exact day on which the last prisoner finally goes to the room for the first time is a bit tricky, since that last person has to know he is the last. This is probably where the switches get into the picture.

Can the prisoners count the days?
December 29th 2006, 10:42 AM
knightg.gif
cypry
Peasant He/Him Romania
Chop your own wood, and it will warm you twice. 
I think he meant consecutively, instead of simultaneously.
December 29th 2006, 05:23 PM
anon.gif
MiloBones
Ghost They/Them
 
Of course they can count the days.
December 30th 2006, 12:17 AM
duckdie.gif
That was kind of lame and not challenging at all. Just counting the days? That solution took me all of 5 minutes to come up with the night he posted it.
December 30th 2006, 06:18 AM
knightg.gif
cypry
Peasant He/Him Romania
Chop your own wood, and it will warm you twice. 
No, that's not the solution. I think he meant that he can take prisoner1 3 days, the next day prisoner2, then again prisoner1, and such. It's only that he's not allowed to take the same prisoner 4 consecutively days.
December 30th 2006, 07:07 AM
milder.gif
Harshit
Peasant He/Him India
Milderr!! 4: Return of the Legend 
I solved these and more like them long time ago. They can be found in the form of flash games on a site(I dont remember).
December 30th 2006, 11:01 AM
knightg.gif
cypry
Peasant He/Him Romania
Chop your own wood, and it will warm you twice. 
Try this one:
100 mathematicians are standing in a line, wearing a black or
white hat. Each mathematician can ONLY see the color of the hats
of the people in front of them. So the first person sees no hats,
the last sees 99.

The mathematicians are allowed to talk to each other and decide
upon a strategy, for a government rep is coming to cut off funding.
Each person can only say 'black' or 'white'. If you correctly say
what color hat you're wearing, your funding is continued and you
live. If you're wrong, you lose your funding, and you may as well
be dead.

How many mathematicians can you guarentee will keep their funding?
You are not allowed you use 'tricks', say a person delays 1 second
before answering means A, 2 seconds means B, .... You have to answer
IMMEDIATELY what color hat you're wearing.
December 30th 2006, 10:01 PM
pq_skull.gif
dinkme
Peasant He/Him India
 
That's not the solution. I made a mistake in my first post. I meant that he could call the prisoner more than 3 times but in this way:
1,1,1,2,2,3,4,7,8,1
He cannot call the same person more than three days consecutively but can call him again after 6 to 7 days. Now you have to tell when exactly all the prisoners have been to the room. Suggest a plan in which you can be 100% sure that all the prisoners have been to the room and yes this puzzle can't be solved in 5 minutes.

All these puzzles my brother had told me, so I don't know if they had come from a website. Try these two:

1. You have 12 coins. 11 of them are of the same weight whereas one of them is heavier than the others. You have a Balance . Find out the heavier coin by not taking more than three measurements.
The difficult version of this puzzle is to find out the heavier coin in not more than two measurements.
December 30th 2006, 10:35 PM
custom_magicman.gif
magicman
Peasant They/Them Netherlands duck
Mmmm, pizza. 
I know the 3 measurements way. I can get the heavier coin out of a total of 9 coins with 2 measurements, but I haven't figured out what happens when there's a total of 12 coins.

3 measurements:

1,2,3,4 VS 5,6,7,8

If left is heavier, continue with 1,2,3,4
If right is heavier, continue with 5,6,7,8
If they have the same weight, continue with 9,10,11,12

4 coins left. For simplicity, assume these are 1,2,3,4.

1,2 VS 3,4

Left heavier: continue with 1,2
Right heavier: continue with 3,4

2 coins left. For simplicity, assume these are 1,2

1 VS 2

And job done!

9 coins in 2 measurements:

1,2,3 VS 4,5,6

Left -> 1,2,3
Right -> 4,5,6
Neither -> 7,8,9

Assume 1,2,3

1 VS 2

Left -> 1
Right -> 2
Neither -> 3

12 anyone?
December 31st 2006, 07:31 AM
knightg.gif
cypry
Peasant He/Him Romania
Chop your own wood, and it will warm you twice. 
The one with the coins is a classical one. I have the solution written somewhere, it's not easy. The one with the prisoners it's simpler than it looks. Try the one i posted