![]() |
technical riddles (people inside & outside a room) The constraint to "move one person in or out" suggests a similarity with Gray code. Assuming that each person is assigned a bit-position, and that the persons inside form a number which is the sum of their bit positions, we need to cycle through all combinations by toggling one bit each time.
Manas
|