# Knights , Knaves and Spies - Part 2

I was working my way through some Knight and Knave Puzzles in Discrete Maths by Rosen, when I came across the following question:

There are inhabitants of an island on which there are three kinds of people:

• Knights who always tell the truth

• Knaves who always lie

• Spies who can either lie or tell the truth.

You encounter three people, A, B, and C.

You know one of these people is a knight, one is a knave, and one is a spy.

Each of the three people knows the type of person each of other two is.

For this situation, if possible, determine whether there is a unique solution and determine who the knave, knight, and spy is :

A says “I am the knight,” B says “I am the knave,” and C says “B is the knight.”

Book Solution:

$$A\Rightarrow Knight$$
$$B\Rightarrow Spy$$
$$C\Rightarrow Knave$$

Doubt:

I am not able to understand why this is the case .

• For A it is fine
• For C it is fine
• But for B , if B is the Spy and B says "I am the knave" -- does that mean B is a Spy who lies ?
• Does each Spy either always lie or always tell the truth (you just don't know which), or does he lie and tell the truth at random, like Jokers in other questions on this site? Dec 30, 2014 at 13:48
• Hi , @randal'thor , The Spies either always lie or tell the truth Dec 30, 2014 at 13:50
• How does that make them a different 'kind of person' then? A Spy must be either a Knight or a Knave (at least in terms of their truthfulness)? Dec 30, 2014 at 13:52
• @randal'thor: A knave always lies. Doesn't mean that a person who always lies must be a knave. Jan 19, 2015 at 17:46
• @pranav No worries, and thank you! :]
– user20
Jan 24, 2015 at 3:07

If C is the knight, then by C's statement, B is the knight, contradiction. If B is the knight, then by B's statement, B is the knave, contradiction. So A is the knight.

If B is the knave, then by B's statement, B is not the knave, contradiction. So B is the spy. And his statement is a lie, so he's a lying spy (now that's a good insult!).

Leaving the last case: C is the knave.

• Hi @randal'thor -- I get your point , but am I right in saying that B is a Spy who lies . And Thanks a bunch :) Dec 30, 2014 at 13:49
• @pranav I've edited my answer. Dec 30, 2014 at 13:53

B cannot be a knight - they would self identify as a knight. They also cannot be a knave - they would self identify as anything but a knave. Therefore they are a spy.

TL;DR: anyone identifying themselves as a knave under these circumstances must be a spy.

Edit: B is indeed a spy who lies. By your answer to rand al'thor, they are a knave in all but name.

• Beat me to it by a minute! :-) +1. Dec 30, 2014 at 13:46
• Hi , @frodosylwalker -- I get your point , but am I right in saying that B is a Spy who lies . And Thanks a bunch :) Dec 30, 2014 at 13:46
• @pranav B is a Spy who is lying in that particular statement - but see my other comment on your question. Dec 30, 2014 at 13:49
• Hi @frodoskywalker - I have added another comment in the question . Please have a look :) Dec 30, 2014 at 13:59
• The question doesn't make it clear whether a spy is either a persistent liar or a persistent truth-speaker or someone who can sometimes lie and sometimes say the truth. Jan 19, 2015 at 17:49