A coin with probability $p$ for heads is rolled time after time. Let $X$ be the number of rolls until we get heads twice. Find the probability mass function $p_x$.
I thought this would entail using the geometric distribution multiplied twice; once for the first roll ($k$ attempts), second for the first roll but according to the given answers it seems my logic is incorrect.
I'd appreciate a correction to my thought process.
Since we're looking for $2$ successes (H), we need to count the number of times it took us to get our first success.
$k$ = number of attempts until first success. $n$ = number of attempts until second success
Therefore there are k+n attempts.
Using geometric distribution:
$$\left((q)^{k-1}p\right)\left(q)^{n-1}p\right)=q^{n+k-2}p^2$$
As I said this answer is incorrect. I'd like to know where I went wrong with my train of thought.