Probability of a specific word appearing in a language is $0.05$. How many words must there be in a text, so that the word appears at least once with a probability of $0.99$?
My understanding is that the random variable $X$ which gives the number of the word's appearances has binomial distribution $B(n, 0.05)$ and I am supposed to find $n$.
Probability mass function is therefore:
$$f(x) = \binom{n}1\cdot0.05\cdot0.95^{n-1}$$
For the word to appear once we have to solve this equation for $n$: $$0.99 = n\cdot0.05\cdot0.95^{n-1}$$ Am I on the right track here? Thanks.
We are looking for $P(n \geq 1) = 1 - P(n = 0)$. But the probability of every word not being the specific word we are looking for is given by:
$$P(n=0)=0.95^{n} = 0.01$$
Solving this for $n$, we have:
$$n\ln(0.95)=\ln(0.01) \implies n=\frac{\ln(0.01)}{\ln(0.95)}\approx 89.78$$
But we want the minimal integer $n$ such that the probability is at least 0.99, so we take the ceiling, $\lceil 89.79 \rceil = 90$.