2
$\begingroup$

I got a question at university which I cannot solve. We are currently working on RSA encryption and I'm not sure what that has to do with the question. Maybe I miss something. Anyway, here is the question:

Inspector D interviews 3 people, A, B and C. All of them give 2 statements, where 1 statement they say is true and 1 is wrong. The inspector knows that and he also knows that exactly one is guilty. Here are the statements:

A: It wasn't me. B did it.

B: It wasn't me. I know that C did it.

C: It wasn't me. B does not know who did it.

So, since there can be only 1 guilty I just looked at each one.

A: If "It wasn't me" is true then "B did it" is wrong. Then Bs 1st statement must be wrong, so C must be the one. But if Cs first statement is wrong it's second must be right, so we have a contradiction.

Same goes for the other two. Am I missing something?

$\endgroup$
4
  • 3
    $\begingroup$ I'm voting to close this question as off-topic because this belongs to Puzzling Beta. $\endgroup$ – RE60K May 8 '15 at 16:24
  • $\begingroup$ From A's statement B cannot be guilty, as if he is then so is A. So since its not B. it must be C It doesnt matter that B does not know that C did it $\endgroup$ – vounoo May 8 '15 at 16:24
  • 1
    $\begingroup$ @ADG off topic means not within the scope of MSE, not a question that might be better addressed on another site. See the second list at the help center here math.stackexchange.com/help/on-topic, and note that solving mathematical puzzles is on the first list which is things that are on topic. $\endgroup$ – jgon May 8 '15 at 16:38
  • $\begingroup$ Thanks for the answers. Hopefully I did not violate any rules, but since logic is a subtopic of maths I thought it was okay. $\endgroup$ – Somebody May 8 '15 at 20:27
1
$\begingroup$

You can easily do this using a truth table:

Statements

$A$ ... A did it.

$B$ ... B did it.

$C$ ... C did it.

$D$ ... B knows who did it.

  • A says: $(\neg A \land \neg B) \lor (A \land B) $
  • B says: $(\neg B \land \neg D) \lor (B \land D) $
  • C says: $(\neg C \land D) \lor (C \land \neg D) $

The truth table \begin{array}{|c|c|c|c|c|c|c|} \hline A& B & C & D & (\neg A \land \neg B) \lor (A \land B) & (\neg B \land \neg D) \lor (B \land D) & (\neg C \land D) \lor (C \land \neg D) \\ \hline 1& 0 & 0 & 0 & 0 & 1 & 0\\ \hline 1& 0 & 0 & 1 & 0 & 0 & 1\\ \hline 0& 1 & 0 & 0 & 0 & 0 & 0\\ \hline 0& 1 & 0 & 1 & 0 & 1 & 1\\ \hline 0& 0 & 1 & 0 & 1 & 1 & 1\\ \hline 0& 0 & 1 & 1 & 1 & 1 & 0\\ \hline \end{array}

Conclusion

As you can see there is only one line where everything in the result is true (the one before the last). So you know that $C$ did it and $B$ did not know it.

Note

(If you're currently taking the course Discrete Mathematics @ TU Graz, it has nothing to do with RSA and belongs to the next chapter, Logic.)

$\endgroup$
2
  • $\begingroup$ Thanks, nicely done :D Did you already attend the course there or are you taking it right now? $\endgroup$ – Somebody May 11 '15 at 19:38
  • $\begingroup$ I'm taking it right now... $\endgroup$ – 今天春天 May 11 '15 at 19:48
2
$\begingroup$

Given the premises of the puzzle, you don't need to go beyond A's statements. If his first statement were false -- i.e., if he did do it -- then his second statement would also be false, in violation of the premise that only one statement is false. So his first statement must be true and the second one false. But that means B didn't do it either, which leaves only C.

You can, if you like, verify that B's and C's statements also satisfy the premises of the puzzle, but there's no actual need to do so, unless you want to make sure the puzzle is properly posed.

$\endgroup$
4
  • 1
    $\begingroup$ copy my answer more please $\endgroup$ – vounoo May 8 '15 at 16:34
  • $\begingroup$ if you agree with an answer upvote it . not copy it. $\endgroup$ – vounoo May 8 '15 at 16:44
  • $\begingroup$ @vounoo, sorry, I did not see your answer. $\endgroup$ – Barry Cipra May 8 '15 at 16:47
  • $\begingroup$ Thank you too for your answer. $\endgroup$ – Somebody May 8 '15 at 20:28
2
$\begingroup$

A's statement is either (t,f) or (f,t). if it is (f,t) it means both him and B are guilty. Assuming there is a solution to this puzzle A is (t,f) and so C is guilty.

Further B is not guilty so his second statement is false. This does not mean C is not guilty, its just that B does not know. Note also C is (f,t) so B does not know who did it anyway.

t=true f=false

$\endgroup$
4
  • $\begingroup$ Thank you very much, I understand. $\endgroup$ – Somebody May 8 '15 at 20:28
  • $\begingroup$ Is there any difference I know C did it and C did it ? $\endgroup$ – Singh May 9 '15 at 13:57
  • $\begingroup$ B does not know who did $\endgroup$ – vounoo May 11 '15 at 21:46
  • $\begingroup$ think about it . $\endgroup$ – vounoo May 11 '15 at 21:46
2
$\begingroup$

c did it, but b doesn't know it, just a lucky guess..

Relation to RSA would be that you have one secret and one public verifiable statement. But it is somewhat abstract.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.