<s>[INST] How to find the probability of $P(Y=6)$ Anna writes down a random sequence created by the following process. She repeatedly rolls a fair
6-sided die. If the number she rolls is larger than all of the numbers she has previously rolled (if
any), then she writes the new number down and then continues rolling. Otherwise, she does not
write the new number down and the process ends.
Let X be the length of Anna’s sequence, and Y be the last number in her sequence.
For example, if Anna rolled 1 then 4 then 5 then 4, her sequence would be 1,4,5 and the random
variables X, Y would take values X = 3 and Y = 5.
Question:
what is $P(Y=6)$
My method

I know I can write down all the possible ways that the last number of the sequence could be 6, and then I add up all the probabilities.

*

*$1,2,3,4,5,6 = (\frac{1}{6})(\frac{1}{5})(\frac{1}{4})(\frac{1}{3})(\frac{1}{2})(1)$

*$2,3,4,5,6 = (\frac{1}{6})(\frac{1}{5})(\frac{1}{4})(\frac{1}{3})(\frac{1}{2})$

*$3,4,5,6 = (\frac{1}{6})(\frac{1}{5})(\frac{1}{4})(\frac{1}{3})$

*$1,2,4,6 = (\frac{1}{6})(\frac{1}{5})(\frac{1}{4})(\frac{1}{3})$
etc.
But this method is way too time-consuming as there are too many possible sequences.
I also tried to do it a different way by using $1 - $(The possible sequences that the last number is not 6), but there are even more sequences to take into account this way.
Can anyone show me a much more efficient way of finding the solution to this problem?
 [/INST] 
Question:


what is P(Y=6)

observe that the sequence's length can only be $X \in\{1,2,3,4,5,6\}$
$X=1$ when you roll immediately 6
$X=5$ when you roll 4 numbers in increasing order, and then 6. The only favourable sequences are, in this case
$1234$
$1235$
$1245$
$1345$
$2345$
...and 6 on the fifth roll. Observe that these cases are exactly $\binom{5}{4}$
thus here the probability to get $Y=6$ is $\frac{5}{6^4}\cdot\frac{1}{6}$
Using this procedure, you easy get
$$\mathbb{P}[Y=6]=\frac{1}{6}+\frac{5}{6}\cdot\frac{1}{6}+\frac{10}{6^2}\cdot\frac{1}{6}+\frac{10}{6^3}\cdot\frac{1}{6}+\frac{5}{6^4}\cdot\frac{1}{6}+\frac{1}{6^6}=\approx 0.36$$
</s>