n represents the number of people.
The probability is that none of these people have a birthday on the same day.
Neglect people that are born on 29 February.
What should n be so that the probability is less than $\frac{1}{2}$
so the probability should be something like this:
$\frac{365Pn}{(365)^n}$ = 0.5
but how to get n?
Try this:
$$\begin{align} \dfrac{\ ^{365}P_n}{365^n}&<\frac 12\\ \frac{365}{365} \cdot \frac{364}{365}\cdot...\cdot\frac{365-n+1}{365}&<\frac 12\\ \left( 1-\frac{0}{365} \right)\left( 1-\frac 1{365}\right)\left( 1-\frac 2{365}\right)...\left( 1-\frac{n-1}{365}\right)&<\frac 12\\ \approx e^{-\frac 0{365}}e^{-\frac 1{365}}e^{-\frac 2{365}}...e^{-\frac {n-1}{365}}&<\frac 12\\ e^{-\frac{n(n-1)}{2\cdot 365}}&< \frac 12\\ \frac{n(n-1)}{2\cdot 365}&>\ln(2)\\ n^2-n-505.997&>0\\ n&>\frac {1+\sqrt{1+4(505.997)}}2\\ n&>22.99994\\ \therefore n&=23 \end{align}$$
And then check manually for n=22, 23, 24 to confirm that the result is correct.