Given a random permutation of 1 to N, what is probability to get $N-1$ with a certain strategy?

130 Views Asked by At

Given a random permutation of $1$ to $N$, let the sequence be $a_1,a_2,\cdots,a_N$.

Erase the first $k$ items, and find out the item (let it be $a_I$) which is first item greater than the fist $k$ items.

I already know that $$P(a_I = N)=\frac{k}{n}\sum_{i=k+1}^{N}\frac{1}{i-1}.$$

But what is the probability of $a_I=N-1$?

Furthermore, what is the expected value of $a_I$?