Fork that leads to two paths

by iarnab_kundu, Dec 29, 2014, 6:48 AM

Say, you are at a fork. There are two roads diverging from it. One of them is unsafe and the other one is safe.
They are identical in all other respects, and you want to discern which one is the safe one.
For your help there are two people standing who can only respond to bool questions. (Like "Is the sky red?")
One of them always speak the truth, and the other always lies. The two persons are identical in all other respects.

You can ask them one question, the same one to both.
And based on their answers you have to choose the right path.

Which question will it be?

My solution-

A: If I ask you "Is 1=1", will you answer yes?
B: If I ask you "Is this road safe?" will you answer yes?

Let $\text{Z }$ be the output we define.
$\begin{matrix}\text{A} & \text{B} & \text{Z}\\ 
1 & 1 & 1\\ 
1 & 0 & 0\\ 
0 & 1 & 1\\
0 & 0 & 0
\end{matrix}$

$\text{A} = 0$ means that the person is liar. The liar says no to the correct path and yes to the other. Thus for him $\text{B} = 0$ means that the road is safe and unsafe otherwise.
Now the liar obviously inverts the values, and if we name $\text{Z}'$ to be the reply we receive then we have
$\begin{matrix}\text{A} & \text{B} & \text{Z}'\\ 
1 & 1 & 1\\ 
1 & 0 & 0\\ 
0 & 1 & 0\\
0 & 0 & 1
\end{matrix}$

If the answer is $1$ then we choose the same path, otherwise choose the next one.

Vipul Naik's solution:
Is at least one these statements true?
(a) You are a liar,
(b) The left road is the correct one."

The liar will always say no, but the other person's answer will be the answer to (b). So if the left road is the correct one, you will get one no and one yes. If the right road is the correct one, you will get two nos.
This post has been edited 4 times. Last edited by iarnab_kundu, Dec 29, 2014, 7:14 AM

Comment

0 Comments

This blog reflects my thoughts on the mathematics that I grapple with. Hopefully these rumblings could be organized as to be palatable to a mathematical audience.

avatar

iarnab_kundu
Tags
About Owner
  • Posts: 866
  • Joined: Jan 12, 2011
Blog Stats
  • Blog created: Mar 9, 2011
  • Total entries: 42
  • Total visits: 27139
  • Total comments: 23
Search Blog
a