Choose $a\in\{1,\ldots,n\}$ and $b\in\{a,\ldots,n\}$, what is the distribution of $b-a$? We uniformly at random choose an integer $a$ from $\{1,\ldots,n\}$. Then, we choose another integer $b$ uniformly at random from $\{a,\ldots,n\}$. 
What is $$\Pr[b-a=t],$$ where $t=0,1,\ldots,n-1$?
Since $a$ and $b$ are dependent, can we still find the probability?
 A: 1. The set of events is:
$$
E:=\{(a, b) \in \mathbb{N}^2 : 1 \leq a \leq n \text{ and } a \leq b \leq n\}
$$
and, for each event,
\begin{align}
\mathbb{P}[\{(a,b)\}] &= \mathbb{P}[\text{The 1st number is a}] \cdot \mathbb{P}[\text{ The second number is b, knowing that the 1st was a}]\\
&= \frac{1}{n} \cdot \frac{1}{n-a+1}
\end{align}
2. Now, we will first determine the possible values of $b-a$ and then we will find all events leading to a possible value.
Notice that $b-a$ is maximal when $b=n$ and $a=1$. In that case, $t = n-1$.
Notice that $b-a$ is minimal when $b=a$. In that case, $t = 0$.
Finally, every integer value between $0$ and $n-1$ can be obtained when $a=1$. Therefore $0, 1, \ldots, n-1$ are the possible values for $b-a$.
3. Fix $t\in\{0, 1, \ldots, n-1\}$. Which events in $E$ will lead to $b-a = t$ ?
The events must be of the form $(a, t+a)$, but not all of these events will be possible for a fixed $t$. Indeed, $b = t+a$ is possible only if
\begin{align}
a \leq b \leq n &\iff a \leq t+a \leq n\\
&\iff a \leq n-t
\end{align}
All in all, $b-a=t$ happens for the following events:
$$
E_t := \{(a,t+a)\in \mathbb{N}^2: 1 \leq a \leq n-t\}
$$
Finally, it is just a matter of summing the probabilities of these events:
\begin{align}
\mathbb{P}[b-a=t] &= \mathbb{P}[E_t]\\
&= \sum_{1 \leq a \leq n-t} \mathbb{P}[\{(a, t+a)\}]\\
&= \sum_{1 \leq a \leq n-t} \frac{1}{n(n-a+1)}\\
&= \frac{H_n - H_t}{n}
\end{align}
where $H_i$ is the $i$-th harmonic number.
4. Hence, the final answer is:
$$
\mathbb{P}[b-a=t] = \begin{cases} \frac{H_n - H_t}{n} & \text{if} \,\,\, t \in \{0, 1, \ldots, n-1\} \\
0 & \text{otherwise}\end{cases}
$$
