Assume people are selected at random, and that their birthdays are uniformly and independently distributed over the 365 days of the year excluding Feb. 29.
- that no one shares a b'day is
- 365 * 364 * ... * 365 - n + 1 / 365 ^ n
and subtract that from 1 to get the odds that two people share a birthday.
For n = 22, this gives a probability of .476, and n = 23 gives .507.
M. Klamkin and D. Newman, Extensions of the birthday surprise, J. Comb. Th. 3 (1967), 279-282.