The Birthday problem. Find the probability that at least two people out of $(k=5)$ people will have the same birthday.
The usual approach would be to use $$p=1-\frac{P_{365,5}}{365^5}$$ However, I want to know what went wrong with my approach: $$ p=\Pr (A_5\cup A_4\cup A_3\cup A_2) $$ where $A_i$ is the event where $i$ persons have the same birthday so $$ p=\frac{1}{365^5}(365^5+365^4 \cdot 364+365^3\cdot 364 \cdot 363+365^2 \cdots362) $$ I used $365^5$ since $5$ people may have the same birthday, therefore we get a value from $365$ with repetition. Furthermore, $4$ people can have the same birthday so we pick $365^4 \cdot 364$ and so on.
This is obviously wrong since $p>1$ however may I ask what went wrong with my thinking?
Let $X$ denote the number of people with the same birth day .
Well $X$ can be either $0$ , or it can be $2,3,4,5$. Because $X=1$ does not make sense
Then $X=0,2,3,4,5$
$$P(X=0)=\frac{\binom{365}{5}\cdot 5!}{365^{5}}$$
$$P(X=2)=\frac{\binom{5}{2}\binom{365}{1}\binom{364}{3}\cdot \frac{4!}{2!}}{365^{5}}$$
and so on
Then $$P(X\geq 2)=1-P(X<2)=1-\frac{\binom{365}{5}\cdot 5!}{365^{5}}$$