The Happy Spork - Photography, Games and More by Ben Anderman

The Princess' Challenge


Once upon a time, in a land inside your mind, there was an awesome princess. The princess knew how awesome she was, and so when the time came to be wed, she wanted to make sure that her new husband was worthy of her hand in marriage. She began by narrowing the list down to all of the knights in the kingdom. From there, she set up a challenge; any knight who could complete the challenge would win her hand in marriage. However, any knight who tried and failed, would have his head chopped off.

The Challenge

In her castle there were 17 bedrooms all in a row, with doors between each adjacent one, and each with a door out to the courtyard. The first night she would sleep in one of the rooms, and each night thereafter she would move to one of the adjacent rooms. The knight would be allowed to check one door each morning, but he must find her within 30 days. The challenge is possible to win by chance, but given the stakes, a good knight should figure out a way to find her no matter what.


Click on the rooms in the order you want to check them, and then click "Check". The program will simulate the scenario 10,000 times, and tell you what percentage of the time your strategy found the princess.

Check Clear Result:

© 2017 Ben Anderman