(a) We need to find the probability that a birthday comes on February 29. Consider a 400 year period- as leap year cycle repeats every 400 years. Number of leap years in this = 400/4 - 4 + 1 = 97. So,
number of days in this period = 365 * 400 + 97 = 146097
In these days February 29 repeats 97 times. So, probability of birthday on February 29 = 97 / 146097
(b) Required probability = 1 - probability that every birthdays are distinct
= 1 - (probability that every birthdays are distinct with 1 birthday being feb 29) - (probability that every birthdays are distinct with none being on February 29)
= 1 - ((365 * 364 * ... 365 - n + 2)/365n) n (400/146097)n-1 (97/146097) - ((365 * 364 * ... 365 - n + 1)/365n) (400/146097)n
(In the second term, we are picking distinct days and probability of a birthday falling on each such day is 400/146097 for any day other than feb 29 and 97/146097 for feb29) (n is used since birthday of any of the n person can come on feb 29)
= 1 - 365Pn-1 n (400/146097)n-1 (97/146097) - 365Pn (400/146097)n