Hacker News new | ask | show | jobs
by flir 737 days ago
The other guard always lies.
1 comments

Link to the logic puzzle that flir is referring to:

https://en.wikipedia.org/wiki/Knights_and_Knaves

Ask what would the other do and do the opposite.
I wonder if you could do that with tristate logic somehow. maybe with more guards or other variables.
Solve for the general case.

Maybe you need num_guards-1 questions?

I doubt you could solve for 50 guards with 1 question.

If you're allowed to create a hypothetical question that translates a hierarchy of guards into Boolean logic, then it doesn't matter how many guards there are.
What are you thinking? I was wondering about dividing them into sets.