★ wanayoo — archive 1999 http://www.howstuffworks.com/question261.htmNouvelle recherche | Portail wanayoo

How Stuff Works
tool bar

Question of the Day
Sponsored by:
Click Here!
TeacherVision.com is a convenient and comprehensive resource designed for teachers by teachers. At http://teachervision.com you will find:

Q&A Archive

HSW keeps a complete archive of previously answered questions to help you find answers quickly. Please Click Here for a complete list of previously answered questions.

Asking Questions

If you would like to ask a question, you can click here.
Each weekday Marshall Brain answers questions submitted by the readers of How Stuff Works in the Question of the Day section of HSW. You can also view previously answered questions in the HSW Question Archive. Here is today's question!

Question

A friend of mine told me that if there are 20 people in a room, there's a 50/50 chance that two of them will have the same birthday. I told him he was crazy, but he proved it to me at a party with 25 people at it. Two people actually had the same birthday! How can such a small group of people have two people with the same birthday in it?

Answer

This phenomenon actually has a name -- it is called the birthday paradox, and it turns out it is useful in several different areas (for example, cryptography and hashing algorithms). You can try it yourself - the next time you are at a gathering of 20 or 30 people (in a classroom, at the office, in a chat room, at a party, etc.), ask everyone for their birth dates. It is likely that two people in the group will have the same birthday. It always surprises people!

The reason this is so surprising is because we are used to comparing our particular birthdays with others. For example, if you meet a person randomly and ask him or her for their birthday, the chance of the two of you having the same birthday is only 1/365 (0.27%). In other words, the probability of any two individuals having the same birthday is extremely low. Even if you ask 20 people, the probability is still low - less than 5%. So we feel like it is very rare to meet anyone with the same birthday as our own.

When you put 20 people in a room however, the thing that changes is the fact that all 20 people are now asking the other 19 people about their birthdays. Each individual person only has a small (less than 5%) chance of success, but you are trying it 20 times. That increases the probability dramatically.

If you want to calculate the exact probability, there are two different ways to do it. The first way involves counting the pairs of people in the room. In a room of 20 people there are 190 possible pairs (20*19/2). Each pair has a probability of success of 1/365 = 0.27%, so a probability of failure of 1 - 0.27% = 99.726%. If you raise the probability of failure to the 190th power, then you get:

So the probability of success is (100 - 59%) = 41%. It turns out your friend was slightly off - you have to have 23 people in the room to get 50/50 odds. If you have 42 people in the room the probability rises to a 90% chance of two people having the same birthday!

The other way to look at it is like this. Let's say you have a big wall calendar with all 365 days on it. You walk in and put a big X on your birthday. The next person who walks in has only a 364 possible open days available, so the probability of the two dates not colliding is 364/365. The next person has only 363 open days, so the probability of not colliding is 363/365. If you multiply the probabilities for all 20 people not colliding, then you get:

That's the probability of no collisions, so the probability of collisions is 1 minus that number.

The next time you are with a group of 30 people, try it!



How Stuff Works Power Panel
Table of Contents
A complete list of all HSW articles

About Marshall Brain
Information about the creator of HSW

Search
Search for any word or concept in HSW

Citing HSW
Information about citing HSW in articles and papers

Question of the Day
Ask questions or browse hundreds in the archive

Books
A variety of books for people interested in how stuff works

HSW Newsletter
Sign up to receive the monthly HSW newsletter

Contacting HSW
Contact HSW directly with email

What's New
Review newsletters to chart HSW's development

Awards
Check out HSW's awards and reviews!

Disclaimer
The disclaimer required by the lawyer

Author Information
Learn how you can write for HSW

HSW Fan Buttons
Link to HSW with these snazzy fan buttons!
Suggestions
Leave a suggestion in the suggestion box


Howstuffworks.com, Inc. How Stuff Works (http://www.howstuffworks.com) is a production of
Howstuffworks.com, Inc.
P.O. Box 40492 - Raleigh, NC 27629
See http://www.howstuffworks.com/contact.htm for contact information

© 1999 Howstuffworks.com, Inc. All rights reserved.





Click Here!