Brain Teasers
The Troll Bridge 2
A bridge was guarded by an evil troll. The troll was very intelligent, but he was also a coward. He was afraid of anyone smarter than him. So every time anyone tried to cross the bridge, the troll would set up a test. If the traveler passed the test, he would be allowed to cross. Otherwise, the troll would eat him.
A traveler came across the bridge. The troll said, "You may only cross my bridge if you know the password." He then wrote thirteen pairs of letters on a rock:
A-V
B-W
C-Q
D-M
E-K
F-U
G-N
H-P
I-O
J-R
L-X
S-T
Y-Z
"These thirteen pairs consist of all 26 letters of the alphabet," said the troll. "The password contains thirteen letters, no two of which are the same. Each pair consists of one letter that is in the password and one other letter. If you wrote out the "other" letters in alphabetical order and then wrote each "password" letter under each one's corresponding "other" letter, you would have the correct spelling of the password."
Then the troll wrote five short words on the rock: FACE, QUEST, QUICK, SWITCH, and WORLD. "Each short word contains exactly the same number of letters with the password," he said.
So, what is the password?
A traveler came across the bridge. The troll said, "You may only cross my bridge if you know the password." He then wrote thirteen pairs of letters on a rock:
A-V
B-W
C-Q
D-M
E-K
F-U
G-N
H-P
I-O
J-R
L-X
S-T
Y-Z
"These thirteen pairs consist of all 26 letters of the alphabet," said the troll. "The password contains thirteen letters, no two of which are the same. Each pair consists of one letter that is in the password and one other letter. If you wrote out the "other" letters in alphabetical order and then wrote each "password" letter under each one's corresponding "other" letter, you would have the correct spelling of the password."
Then the troll wrote five short words on the rock: FACE, QUEST, QUICK, SWITCH, and WORLD. "Each short word contains exactly the same number of letters with the password," he said.
So, what is the password?
Hint
Q cannot exist in the password without U.Answer
The password is UNPREDICTABLY.Exactly one of S and T must be in the password. So QUEST, and so each word, must have at least one letter in common with the password.
Suppose each word has one common letter . Then none of Q, U, and E can be in the word, so C, F, and K must be in the word. But now FACE has at least two letters in common.
Suppose each word has two common letters. The second common letter in QUEST cannot be Q. Suppose it is U. Then C and K must be in the password and F cannot. But now QUICK has at least three common letters.
Suppose the second common letter in QUEST is E. Then C and F must be in the password and K cannot. But now FACE has at least three common letters.
Suppose each word has four common letters. Then Q, U, and E must be in the password, and C, F, and K cannot. But now FACE has at most two common letters.
So each word has three common letters. The second and third common letters in QUEST cannot be Q and E. Suppose they are Q and U. Then K must be in the password, and C and F cannot. But now FACE has at most two common letters.
So the second and third common letters in QUEST must be U and E. Then C must be in the password, and F and K cannot. The third common letter in FACE must be A, so V cannot. The third common letter in QUICK must be I, so O cannot.
Like QUEST, SWITCH contains both S and T. I and C are in the password, so W and H cannot. Since neither W nor O can be in the password, the three common letters in WORLD must be R, L, and D, so J, X, and M cannot.
Writing each determined "other" letter in alphabetical order, and writing each "password" letter under its corresponding "other" letter, we get:
F H J K M O Q V W X
U P R E D I C A B L
The pairs S-T and Y-Z can each only be placed in one spot here:
F H J K M O Q S V W X Y
U P R E D I C T A B L Z
Our 13th pair can now clearly be placed in only one spot:
F G H J K M O Q S V W X Z
U N P R E D I C T A B L Y
Hide Hint Show Hint Hide Answer Show Answer
What Next?
View a Similar Brain Teaser...
If you become a registered user you can vote on this brain teaser, keep track of which ones you have seen, and even make your own.
Solve a Puzzle
Comments
Another fun logic puzzle! At first I did not see how to attack this, then I landed on the QU pair. That got me going. It was the perfect hint for those who didn't see it. I did not follow the given logic, using a bit of intuition instead of computer-like decuction.
Assume QU are in, leads to contradiction, so Q is out and C is in.
(ST) is both in and out of QUEST and SWITCH.
Assume that E is most likely in the password and K is out.
If U is out, F is in. Quest has 2 and Face has 3, so U is in and there are three matches.
So, A is in to give FACE 3 matches.
So, I is in and O is out to give QUICK three matches.
SWITCH has three mathes, so W and H are out.
RLD are in to give WORLD three matches.
List alphabetically and solve.
Assume QU are in, leads to contradiction, so Q is out and C is in.
(ST) is both in and out of QUEST and SWITCH.
Assume that E is most likely in the password and K is out.
If U is out, F is in. Quest has 2 and Face has 3, so U is in and there are three matches.
So, A is in to give FACE 3 matches.
So, I is in and O is out to give QUICK three matches.
SWITCH has three mathes, so W and H are out.
RLD are in to give WORLD three matches.
List alphabetically and solve.
To remove the assumption, assume E is out. Then K is in. QUEST must have two, so U is in. Now QUEST has two and QUICK has three. So, E is in.
This brain teaser can be formulated as a set of linear equations of integer and boolean variables.
The scip model I used (available at https://gist.github.com/saska- gist/f99b5c137d31a085f5c858bdf6bc7d01 ) produces the solution
password: UPREDGICSABLY
(other word: FHJKMNOQTVWXZ)
which required the manual flipping of the pairs G-N and S-T.
The scip model I used (available at https://gist.github.com/saska- gist/f99b5c137d31a085f5c858bdf6bc7d01 ) produces the solution
password: UPREDGICSABLY
(other word: FHJKMNOQTVWXZ)
which required the manual flipping of the pairs G-N and S-T.
To post a comment, please create an account and sign in.
Follow Braingle!