A man owned a casino and invited some friends.
It was a dark stormy night, and they all placed their money on the table right before the lights went out.
When the lights came back on, the money was gone.
The owner put a rooster in an old rusty tea kettle.
He told everyone to get in line and touch the kettle after he turned the lights off, and the rooster will crow when the robber touched it.
After everyone touched it, the rooster didn't crow, so the man told everyone to hold out their hands.
After examining all the hands, he pointed out who the robber was.
How did he know who stole the money?
Because the tea kettle was rusty, whoever touched it would have rust on their hands. The robber didn't touch the kettle, therefore he was the only one whose hands weren't rusty.
Bill and Stacie are delighted when their new baby, Patrick, is born on February 29th, 2008. They think it's good luck to for him to be born on the special day of the leap year. But then they start thinking about when to celebrate his next birthday. After some thought, they decide that they want to celebrate Patrick's next birthday (when he turns 1) exactly 365 days after he was born, just like most people do.
What will be the date of this birthday?
The date of the birthday will be February 28th, 2009.
At first it might seem like his birthday should be March 1st, 2009, since February 29th is the day after February 28th in the leap year, while March 1st is the day after February 28th in non-leap years. But this is the wrong way to think about it.
The right way to think about it is that 365 days after the day before March 1st is always February 28th, regardless of whether it's a leap year or not. So Patrick's birthday will be February 28th.
Suppose you want to send in the mail a valuable object to a friend. You have a box which is big enough to hold the object. The box has a locking ring which is large enough to have a lock attached and you have several locks with keys. However, your friend does not have the key to any lock that you have. You cannot send the key in an unlocked box since it may be stolen or copied. How do you send the valuable object, locked, to your friend - so it may be opened by your friend?
Send the box with valuable object and a lock attached and locked. Your friend attaches his or her own lock and sends the box back to you. You remove your lock and send it back to your friend. Your friend may then remove the lock she or he put on and open the box.
Search: Man-in-the-middle attack