The Unexpected Hanging Paradox: How To Resolve It? - An illustration showing a cute little coconut with eyes and mouth on the left. On the right, you can see a female prisoner who is unhappy. In between them is a hanging rope. The prisoner sadly asks, "All this for a coconut?"

The unexpected hanging paradox arises from a puzzle that challenges the fundamental philosophy of logic. A modern game theorist might argue that this puzzle belongs to her domain. But as far as I could look, the unexpected hanging puzzle existed way before the existence of modern game theory (by word of mouth).

Donald John O’Connor, a philosopher at the University of Exeter was the first person to write about this paradox in print (in 1948). Following his work, several logicians, mathematicians, and philosophers began a fierce discussion about the paradox via articles in journals.

Michael Scriven, who was the professor of the logic of science at the University of Indiana, wrote the following about the unexpected hanging paradox in his article in 1951:

“A new and powerful paradox has come to light.”

Over the years, a wide range of intellectual minds have discussed several versions of this paradox. But till date, we have no consensus. In this essay, I will begin by presenting a simple yet well-known version of this paradox.

Following this, I will discuss a reasonable resolution to the paradox as well; yes, it might just be possible! Finally, I will touch upon some interesting and engaging events surrounding this paradox. Without any further ado, let us begin.

This essay is supported by Generatebg

A product with a beautiful background featuring the sponsor: Generatebg - a service that generates high-resolution backgrounds in just one click. The description says "No more costly photographers" and displays a "Get Started" button beneath the description.

The Unexpected Hanging Paradox — The Puzzle

Our story starts with an unfortunate prisoner. All she did was steal a coconut to appease her hunger. She almost got away with it too, if it were not for a bunch of meddling kids and their dog. They saw her pocket the coconut and promptly notified the shopkeeper. The shopkeeper, in turn, promptly notified the law.

The Unexpected Hanging Paradox: How To Resolve It? — An illustration showing the prisoner stealing the cute little coconut. The prisoner seems really happy with the coconut.
The prisoner and the coconut — Illustrative art created by the author

The law in our fictional world is known for its mercilessness. The law enforcers took her into custody straightaway. Today is Saturday, a day after her arrest. As our prisoner and her lawyer stand before the judge, he passes the following judgement on her:

“I sentence you to death by hanging! Your hanging will take place at noon of one of the seven days of next week. I will make sure that you will not and cannot know which day it is before I personally inform you on the morning of the day of your hanging. Let this be a lesson to all the coconut thieves out there!”

Shocked by this judgement, our prisoner hopelessly returns to her cell whilst being accompanied by her lawyer. The judge has a solid track record; he has always kept his word until this point. So, our prisoner knows for sure that the judge will go through with his sentence no matter what it takes.

On their way back, as soon as our prisoner and her lawyer find themselves alone for a moment, the lawyer unveils a thankful smile and sigh of relief. He exclaims the following:

“What luck! Don’t you realise?! The judge’s sentence leads to a logical contradiction and cannot be carried out!”

Puzzled, but hopeful, the prisoner begs her lawyer to tell her more about it.


Is There Any Hope for Our Prisoner?

The lawyer starts by revealing the following logical analysis to our prisoner:

“The judge said that he will make sure that you will not and cannot know the day of your hanging in advance. This means that it cannot be Saturday. This is because Saturday is the last day of the week.”

Puzzled by this analysis, our prisoner asks “But why?!” To this, the lawyer responds:

“If the judge indeed plans to hang you on Saturday, you will live through all of the days of the week. To be very clear, you will still be alive on Friday at noon. Based on this fact alone, you can be sure that your hanging is on Saturday at noon.

Now, consider the fact that the judge assured you that you will not and cannot know the day of your hanging in advance. You will know which day it is if it were on Saturday. So, we can safely rule out Saturday!”

Armed with little more hope and a shaky voice, our prisoner asks, “But what about the remaining days of the week? Does this just not mean that I will die before Saturday?” To this, the lawyer responds:

“Not quite! We already know that your hanging day cannot be Saturday. If it were Friday, you would still be alive on Thursday at noon. Now, consider the fact that the judge assured you that you will not and cannot know the day of your hanging in advance.

Based on this, we can rule out Friday as well. If we continue to apply this logic recursively, we can eliminate all the remaining days of the week.

In short, the judge has made a logical error. His sentence leads to a circle of logical contradictions. You can rest assured that you will live through this.”

After hearing this, our prisoner feels relieved and cheerful. No matter which way she thinks, her lawyer’s logical reasoning seems unshakable to her. That night, she goes to sleep with more hope than ever.

The Unexpected Hanging Paradox — Revealed

An entire day passes by and nothing happens. On Monday evening, our prisoner starts to wonder what will happen after Saturday. That is, what would become of her after the judge realises his mistake?

As she ponders upon the various possibilities of her future life, she falls asleep that night.

The Unexpected Hanging Paradox: How To Resolve It? — An illustration showing a cute little coconut with eyes and mouth on the left. On the right, you can see a female prisoner who is unhappy. In between them is a hanging rope. The prisoner sadly asks, “All this for a coconut?”
The unexpected hanging paradox — Illustrative art created by the author

On Tuesday morning, to her shocking horror, the judge appears before her cell with the hangman. Too shocked to even feel despair, she prepares to surrender to her unfortunate fate.

That is where we step in. Do you think we can figure out where our prisoner and her lawyer went wrong?

Let’s start with the judge’s sentence. The judge said that he would ensure that the prisoner will not and cannot know of her day of hanging in advance. Furthermore, the judge has always kept his word to date.

Based on these factors, the lawyer came up with a seemingly air-tight logic. According to this logic, the prisoner could rule out all the days of the week, as the judge’s sentence would lead to a circle of contradictions.

In short, there is no logical contradiction in the judge’s sentence in itself. However, it cannot be practically executed, without altering or violating the judge’s definition of his sentence. In reality, though, our prisoner never managed to know of her day of hanging in advance.

The judge delivered on what he set forth to do. Does this not mean that the judge’s sentence was logically and practically valid all along? So, how can the judge’s logic AND the lawyer’s logic both be valid at the same time? This, in essence, is the core of the unexpected hanging paradox.


A Potential Resolution

One of the strong assumptions we make in this puzzle is that the judge would stick to his word no matter what. While it is true that the judge has always kept his word to date, this should (logically) be no proof that he would stick to his word in the future also.

So, if we cannot trust the judge’s words, then the prisoner and the lawyer have no rational basis for deducting the day of her hanging in the first place. Furthermore, if the prisoner and the lawyer cannot rationally deduce the day of her hanging, they just confirm the judge’s logic.

In essence, we could conclude that the paradox is caused because of the judge’s (potentially flawed) formulation. An analogy for this kind of formulation was proposed by English mathematician Philip Jourdain in 1913:

The Unexpected Hanging Paradox: How To Resolve It? — An illustration showing a card on the left, on which the following sentence is written: “The sentence on the other side of this card is true.” The flipped version of the card is shown on the right. On this side, the following text is written: “The sentence on the other side of this card is false.”
Jourdain’s card — Illustrative art created by the author

One more funny analogy that comes to my mind is a clip of a dog relentlessly chasing its tail. Some might find this resolution convincing. But the fact is that a lot of intellectual minds do not.

But worry not, I came across an even more convincing resolution for this paradox.

The Unexpected Hanging Paradox — Resolved?

The resolution that I am about to present was originally conceived by Scottish Mathematician Thomas H. O’Beirne. He presented it in his work titled “Can the Unexpected Never Happen?” in 1961.

According to O’Beirne, the key to cracking this paradox lies in the following realisation: The statement that the judge makes about the future event (the prisoner’s hanging) is true from his point of view. However, the same statement is not true from the prisoner’s point of view until it has occurred.

What the lawyer actually did is to use this untested predictive statement to construct a chain of logic that ultimately discredits the predictive statement itself; proof by contradiction, if you will.

The prisoner and her lawyer assume that the prediction is not true until the event (the prisoner’s hanging) occurs for both themselves AND the judge. However, in reality, it is true for the judge even before the event occurs. Therein lies the root of the paradox.

The assumption about the global truth of the prediction drives the problem into a structure similar to the sentences on Jourdain’s card.

The Unexpected Hanging Paradox: How To Resolve It? — An illustration showing a card on the left, on which the following sentence is written: “The sentence on the other side of this card is true.” The flipped version of the card is shown on the right. On this side, the following text is written: “The sentence on the other side of this card is false.”
Jourdain’s card — Illustrative art created by the author

An Analogy to the Resolution

To make better sense of O’Beirne’s resolution, consider the following scenario, where a father says to his beloved son:

“Dear Son,

I promise you that I will surprise you on your birthday with a gift. You cannot and will not be able guess what your birthday gift is. It is the video game console that you were looking at last weekend.

I have never failed to deliver on my promises before and will do my utmost best to deliver this time as well.”

How should the son go about making sense of this? He has absolute faith in his father’s promise. However, if his gift will indeed be the video game console, he would hardly be surprised come his birthday. And this would mean that his father’s prediction would not be true.

On the other hand, if his gift will not be the video game console, then his father has broken his promise.

There are two alternatives here:

1. The father breaks his promise/prediction by not surprising his son on his birthday and gifts him the video game console.

2. The father breaks his promise/prediction about the video game console by gifting him something else on his birthday.

From the son’s perspective, because of the self-refuting nature of his father’s statements, the son has no rational basis for expecting either of these alternatives. So, the father would keep his son guessing until his birthday.

When the said birthday arrives, the son is surprised to get the video game console as he did not logically expect to get it.


Some Interesting History Behind the Unexpected Hanging Paradox

When reading an account on this paradox written by Martin Gardner, a mathematics teacher from Sweden named Lennart Ekbom was struck by a memory. Back in 1943/44, it seems that the Swedish Broadcasting Company announced of a civil-defense exercise in the week following the date of announcement.

This exercise was meant to test the efficiency of the civil-defense units. So, the test was designed such that no one would be able to predict the day of the exercise, even on the morning of the exercise day.

Ekbom sharply noticed the paradoxical nature of this announcement and remembers discussing the issue with some mathematics and philosophy students at Stockholm University. When one of these students visited Princeton in 1947, he heard Kurt Gödel, the then famous mathematician, discuss a variant of this paradox.

From what I could research, variants of this paradox have been spreading by word of mouth for a long, long time. However, it could very well be the case that the announcement made by the Swedish Broadcasting Company is the first recorded real-life instance of this paradox with a practical intent.

On that interesting note, I end this essay. I hope you enjoyed the discussion!


Reference and credit: Martin Gardner.

If you’d like to get notified when interesting content gets published here, consider subscribing.

Further reading that might interest you:

If you would like to support future content, consider contributing on Patreon.

Street Science

Explore humanity's most curious questions!

Sign up to receive more of our awesome content in your inbox!

Select your update frequency:

We don’t spam! Read our privacy policy for more info.