# Logic Puzzle

Gastel
Posers and Puzzles 18 Apr '06 19:31
1. 18 Apr '06 19:31
I apologize if this has been described before (I didn't read all 20 pages of posts before posting this).

The object of this game is to turn four "shot glasses" either all UP or all DOWN. The shot glasses are placed out of sight in the bottom of 4 "pockets" in a special pool table with only 4 pockets (1 in each pocket). Using only your hands (and not peeking inside), you are allowed to reach into any two pockets and flip one or two shot glasses, or simply leave them alone. When you pull your hands out one of two things happen: 1) A bell goes off indicating that all of the glasses are in the same orientation or 2) Not all of the glasses are in the same orientation and the table spins around at incredible speed - the effect of which is that when it stops you do not know which two pockets you just put your hands in.

The problem: What is the minimum number of hand "dips" that are required to guarantee that all of the glasses are in the same orientation? (Fore example: The answer of 1 is not correct because even though you may have been lucky and managed to do it, you couldn't guarantee that you had done it.)
2. TheMaster37
Kupikupopo!
19 Apr '06 09:06
Originally posted by Gastel
I apologize if this has been described before (I didn't read all 20 pages of posts before posting this).

The object of this game is to turn four "shot glasses" either all UP or all DOWN. The shot glasses are placed out of sight in the bottom of 4 "pockets" in a special pool table with only 4 pockets (1 in each pocket). Using only your hands (and not peek ...[text shortened]... may have been lucky and managed to do it, you couldn't guarantee that you had done it.)
It's possible you will never get the glasses right.

If after the first dip you manage to get three glasses in the same orientation the table spins.

After that you can't be sure that you'll ever pick the one glass that's still not right.'

What I'm saying is that it's possible that you keep picking the same two holes (due to the random configuartion of the table ofter a miss).
3. 20 Apr '06 00:41
There is a solution. I promise. I can give a hint, but only if you need one.
4. 20 Apr '06 01:321 edit
Originally posted by Gastel
There is a solution. I promise. I can give a hint, but only if you need one.
Question: When you say that you are allowed to 'dip' your hands into two pockets, are both pockets necessarily being investigated simultaneously? Is it permissible to sample one pocket, and only then to choose to sample another pocket? Or is it a case in which the set of two pockets must be fully specified before sampling either member of the set?
5. 20 Apr '06 01:37
You 'dip' your hands at the same time, so the set is sampled simultaneously. (There is also, never any point in dipping your hand into just one pocket.)
6. BigDoggProblem
Court Jester
20 Apr '06 06:322 edits
I've found a solution, assuming two things are true:

1) The pool table is still rectangular, despite having only 4 pockets
2) The glasses do not start out in the same state

7 grabs will test all possible combinations of shot glass states. I label the pockets:

B_____C
A_____D

The letters are always relative to my position, and are not absolute labels of the pockets, since I do not know which is which after a spin.

Change CD, BD, CD, D, BD, CD, BD and the bell should ring after one of the changes.

If it is possible for the glasses to start in the same state, I would start with a changeless grab (bringing total up to 8) to test for that state.
7. 20 Apr '06 10:32
Interesting, but you can do it in fewer and with a square table instead of a rectangular table. (I hadn't thought about that aspect, but it should be a square table. - meaning there is absolutely no information as to which pockets are in front of you after a spin.)
8. TheMaster37
Kupikupopo!
20 Apr '06 12:331 edit
Originally posted by Gastel
Interesting, but you can do it in fewer and with a square table instead of a rectangular table. (I hadn't thought about that aspect, but it should be a square table. - meaning there is absolutely no information as to which pockets are in front of you after a spin.)
I can get 3 glasses right, but the fourth glass presents a problem. I don't see how you can be sure you'll ever get the fourth one in your hands...

Though this should be a temporary problem ðŸ™‚ I'm still thinking on it.

EDIT: there are four sides you can choose, and two diagonals. I'm inclined to believe that no matter what, due to the randomisation you can't be sure you'll ever pick the hole with the last glass...
9. BigDoggProblem
Court Jester
20 Apr '06 18:22
Originally posted by Gastel
Interesting, but you can do it in fewer and with a square table instead of a rectangular table. (I hadn't thought about that aspect, but it should be a square table. - meaning there is absolutely no information as to which pockets are in front of you after a spin.)
Seems I can still do it in 7 grabs on a square table (changes the types of grabs a bit), but I'm not able to reduce the number of grabs below 7. Would you mind PM'ing the solution?
10. BigDoggProblem
Court Jester
20 Apr '06 22:50
Originally posted by BigDoggProblem
Seems I can still do it in 7 grabs on a square table (changes the types of grabs a bit), but I'm not able to reduce the number of grabs below 7. Would you mind PM'ing the solution?
OK, just had a PM convo with gastel. My solution is based on the player NOT being able to tell the position of the glasses by touch; in his, the player IS able to tell.
11. 21 Apr '06 12:12
I think I have the solution in 6 'dips' and I used touch

1. flip two diagonal glasses so they are up
2. flip two horizontal glasses so they are up
3. put your hands in two horizontal pockets.. if one glass is down flip it up if both are up flip one down
4. put your hands in two diagonal pockets.. if the glasses are the same flip them if they are different leave them
5. flip two glasses regardless of their position in two of the horizontal pockets
6. flip two glasses in diagonal pockets

It's easier to understand if i drew diagrams, but I'm lazy. In one of the steps the bell should've rung, I think. Nice puzzle, took me a while. I just hope i did it correctly.
ðŸ˜•
12. BigDoggProblem
Court Jester
21 Apr '06 17:50
Originally posted by angelswings
I think I have the solution in 6 'dips' and I used touch

1. flip two diagonal glasses so they are up
2. flip two horizontal glasses so they are up
3. put your hands in two horizontal pockets.. if one glass is down flip it up if both are up flip one down
4. put your hands in two diagonal pockets.. if the glasses are the same flip them if they are di ...[text shortened]... should've rung, I think. Nice puzzle, took me a while. I just hope i did it correctly.
ðŸ˜•
Looks good to me. It seems there are many 6-dip solutions. Here is the one I sent to gastel:

The glasses are in one of these four states:
UD UU UU DD
DU DD UD DU
(I'll call them states 1-4 respectively)

1) Dip diagonally. If glasses are in the same state, flip both. If not, flip them to UU.
Either solves state 1, converts state 2 to 3, or converts state 4 to 1 or 3. If the game goes on, the glasses are in state 1 or 3.

2) Repeat step 2.
Solves state 1, if it exists. May also get lucky and solve state 3. If not, state 3 converts to 4 and the game continues.

3) Dip anywhere; if you get two D, change one of them to U; if not, change the U to D.
Either wins, or converts to state 1 or 2.

4) Dip diagonally. If glasses are in the same state, flip both.
Either wins (if in state 1), or continues in state 2.

Converts state 2 to state 1 (or wins, if lucky).

6) Dip diagonally. Flip both.
Wins.

Perhaps the problem would be improved by removing the ability to tell the position of the glasses by touch. I was able to solve it in 7 dips. Is there only one solution?
13. 22 Apr '06 00:20
Originally posted by BigDoggProblem

Perhaps the problem would be improved by removing the ability to tell the position of the glasses by touch. I was able to solve it in 7 dips. Is there only one solution?[/b]
I don't know would the table be rectanguler?

I was actually considering whether or not the table would have two pool ball holders at the side because it was a pool table.It might have made the problem easier.
14. BigDoggProblem
Court Jester
22 Apr '06 03:27
Originally posted by angelswings
I don't know would the table be rectanguler?

I was actually considering whether or not the table would have two pool ball holders at the side because it was a pool table.It might have made the problem easier.
The table can be square and 7 dips still solves.
15. uzless
The So Fist
22 Apr '06 03:47
I can do it in 2.....

1...reach diagonally and take out 2 shot glasses...if remaining 2 shot glasses are same orientation bell rings...if not,

2...reach vertically or horizonatally (doesn't matter)...if you only find one shot glass, turn it over the other way....if you find 2 shot glasses, turn them both up.

This way you can GUARANTEE that all shot glasses in the POCKETS are the same

>:-)