Lucky Six scratch tickets all have an independent probability of $0.05$ Hey guys any tips would be appreciated.
Suppose Lucky Six scratch tickets all have an independent probability of $0.05$ of being a winner. Kathy will keep buying scratch tickets until she
*

*gets a winner or 

*she has scratched 20 tickets, which ever comes first.
Let $X$ be the number of scratch tickets she buys. Find the pmf of $X$.
What is the probability she buys less than $17$ scratch tickets? 
I think that the pmf is $$P(X=x)=p(1-p)^{x-1}, \quad x=1,2,3, \cdots,20$$ since the probability is constant from attempt to attempt and that we are dealing with a geometric distribution.
Furthermore, the probability that she buys less than $17$ scratch tickets is
\begin{align*}
P(X<17)&=1-(P(X=17)+P(X=18)+P(X=19)+P(X=20))\\
&=1-\sum_{x=17}^{20} p(1-p)^{x-1}=1-0.08164=0.9183.
\end{align*}
Is this a viable solution? If not can I get a few tips to tackle this kind of problems?
 A: The pmf looks good.
For the next part, you must also account for the probability that you get $20$ consecutive failures.
We have
$$\begin{align*}
P(X<17)
&=1-[P(X=17)+P(X=18)+P(X=19)+P(X=20)+0.95^{20}]\\\\
&=0.5598733
\end{align*}$$ 
This can be calculated in R statistical software
> 1-sum(dgeom(16:19,.05))-.95^20
[1] 0.5598733

CDF Approach:
The CDF of a geometric distribution is given by
$$\begin{align*}
F_X(x)
&=P(X\leq x)\\\\\
&=1-(1-p)^x\\\\
&=1-0.95^{16}\\\\
&=0.5598733
\end{align*}$$
where in this case we wanted to find $P(X\leq16)$
Alternative Solution:
She will buy less than $17$ tickets only if she has a success on trial number $1,2,3,..,16$
This happens with probability 
$$\sum_{x=1}^{16}p(1-p)^{x-1}=0.5598733$$
This can be calculated in R statistical software as well
> pgeom(15,.05)
[1] 0.5598733

A: It's almost correct. In particular, what is $P(X=20)$? In your formulation, it's the probability that she stops on the 20th ticket because that was a winning ticket. However, the problem says she stops on the 20th ticket regardless of whether or not it was a winning ticket (i.e. if tickets 1-19 were not winning tickets).
In short, if she unconditionally stops on ticket number $t$, then $P(X=t) = (1-p)^{t-1}$, which is a higher probability than what your model assigns it.
The rest of your setup seems to be correct, so you only need to modify $P(X=20)$.
