Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Suppose there are 40 people in a room and I want to know the probability of exactly 2 people having the same birthday (excluding leap years). The probability of two people having the same birthday is $\displaystyle \left(\frac{1}{365} \right)^2$. So out of the 40 people, if I only want 2 people to have the same birthday, then the probability should be $\displaystyle \left(\frac{1}{365} \right)^2 \binom{40}{2}$.

Could someone check my reasoning?

share|cite|improve this question
Use the same reasoning with the population of the entire earth. Do you think the probability $$\left(\frac{1}{365}\right)^2\binom{\approx 7\times 10^9}{2}\ggg 1$$ makes sense? – Zev Chonoles Feb 10 '13 at 0:14
@ZevChonoles: No you're right, my reasoning is definitely off. Could you give me a hint as to how to proceed? – Student Feb 10 '13 at 0:16
It requires a Permutation and the number of days in a year raised to an exponent. – user42538 Feb 10 '13 at 0:20
Once you've choosen two people to have the same birthday, you're not taking into account that the other 38 people have distinct birthdays (both amongst themselves and from the two people with the same birthday). Also, the probability that two people have the same birthday is $1/365$, not $(1/365)^2$. – David Mitra Feb 10 '13 at 0:21
Actually, give two people, the probability for them to have the same birthday (using the standard idealizations about birthday problems) is $1/365$, not $(1/365)^2$. The latter is the probability that both are born on February 10, and doesn't count the possibility that they may share a different date. – Henning Makholm Feb 10 '13 at 0:23

Since this problem is tagged in homework, I am going to try and give several hints that should lead toward the answer and the correct reasoning. In this context we can think of the probability of event is (number of ways this event can happen)/(number of possible events). So look at the following questions:

  1. How many different ways can birthdays be assigned to 40 people. You should expect this to be a pretty big number.
  2. How many ways can birthdays be assigned and have exactly 2 people share the same birthday?
  3. Using this and (number of successes)/(number of events), can you give a reasonable calculation?
  4. As a check in reasoning, remember that if we had more than 367 people, then we can no longer have exactly 2 people with the same birthday. At least 2 different pairs of people would share the same birth date (or three or more would share the same) which makes the desired event impossible. So whatever formula you construct must exhibit this behavior.
share|cite|improve this answer
I see that the first question is $365^{40}$. Would the second be $\binom{40}{2}$? – Student Feb 10 '13 at 0:43
Think about how you answered question 1, and you will see that $\binom{40}{2}$ is not giving the same information. If exactly 2 people share the same birthday, that means that the remaining 38 people must have different birthdays from each other and from the two who have the same birthday. Think of a simpler case where you have three people, can you answer the question then? – Carl Morris Feb 10 '13 at 23:49

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.