This is a longstanding puzzle, first published in 1963 - we hope that you enjoy it.
A prisoner is sentenced to death by hanging, and to make the punishment more severe the hanging will be a surprise. The judge announces that the prisoner is to be hanged at noon on a weekday next week, and the prisoner will not know if he is to be executed that day until there is a knock on the cell door at midday, summoning him to the gallows.
The prisoner is delighted at this, reasoning as follows:
I can't be executed on a Friday, as if there has been no knock on the door by noon on Thursday the execution will not be a surprise.
Similarly I can't be executed on Thursday for the same reasons, as I know I can't be executed on Friday.
And by extension I can't be hanged on Monday, Tuesday or Wednesday either, so I'm free.
Then on Wednesday there is a knock on his door, which was a complete surprise to him, and he was hanged.
So where is the flaw in his reasoning?
Unfortunately there is no agreement on a solution to this - search for Unexpected Hanging Paradox for more information.