Expected number of times to pick from $k$ numbers until you've seen $2$ different numbers You pick a number from the set $\{1,2,\dotsc,k\}$ uniformly at random repeatedly until you see two different numbers. What is the expected number of picks you have to make? I can think of two approaches to this problem, but they give different solutions. I'm confident that the first approach is correct, so my question is more about what's wrong with the second.
First approach: expected number $n$ of picks to see $2$ numbers
The probability that it takes you exactly $n$ tries, and no fewer, to see $2$ different numbers is the probability that picks $2,\dotsc,n-1$ match pick $1$ times the probability that pick $n$ does not. This probability is $(1/k)^{n-2} \cdot (k-1)/k$. Calculating the expected number of tries then is given by the sum $$\sum_{n=2}^\infty n \cdot \left[ \left( \frac 1k \right)^{n-2}\frac{k-1}{k} \right] = \frac{2k-1}{k-1}.$$
Second approach: expected amount of numbers seen after $n$ picks
After picking $n$ numbers, the probability that you will have seen any particular $j \in \{1,\dotsc,k\}$ is $1-((k-1)/k)^n$. There are $k$ numbers one could possibly see, so after $n$ picks you expect to have seen $k\left(1-\left(\frac{k-1}{k} \right)^n\right)$ of the numbers. We want to find out when we expect to have seen $2$ of the numbers, so we set this quantity equal to $2$ and find that the number of picks $n$ should be $$\frac{\log_k(k-2)-1}{\log_k(k-1)-1}.$$

As you can see, these do give different answers. They both seem reasonable post hoc in that they both give a limiting answer of $2$ picks as the size $k$ of the set tends to infinity. That makes sense since with an exceedingly large set of integers to choose from, it is quite likely that your second pick will be anything but your first. But still, the two calculations yield different results for any finite $k$. So what's going on here? I have a hunch the difference would be clear if I tried to be rigorous about probability spaces and random variables and such, but I'm not entirely sure how to implement that here.
 A: Your termination condition is picking two distinct numbers. This is a different termination condition from picking enough times to yield an expected 2 distinct numbers among your picks.
That these conditions are different can intuitively be seen by realizing that the second approach cares about activity after the 2 distinct numbers are picked. After all, whatever the computed number $c$ turns out to be, there is a nonzero probability that the first $c$ picks are identical, and so the computed expectation incorporates cases when 3 or more distinct numbers are seen in those $c$ to balance out the case when only 1 distinct number is seen in those $c$. But the first approach does not care about activity after the 2 distinct numbers are picked. So they must be computing different things.
Another observation that makes the incorrectness of Approach 2 clear: how many picks does it take from a set with $k=2$ elements to yield an expected 2 distinct numbers? Clearly the answer to this question is infinity.
A: The first answer is correct, here's a faster way to get it:
By full symmetry, it doesn't matter what you get for your first pick. Let's assume then that you picked the number $1$. The game now becomes whats the expected value to pick a number $\{2,3,...,k\} $.
You might regocnise this as a geometric random variable. If you have independent consecutive trails with success probability $p$ then the expected number of trails required for the first success is $\frac{1}{p} $. For example it takes on average two tosses of a coin for a head or six rolls of a dice to roll a six.
Hence your $p = \frac{k-1}{k}$ and so your expected value is $1 + \frac{k}{k-1} $.
The one selection it took to the $1$ and then the expected $\frac{k}{k-1}$ to get a $\{2,3,...,k\} $
$1+ \frac{k}{k-1} = \frac{2k-1}{k-1}$
