Let $X_i ~ \sim \operatorname{Exp}(1), \text{ i.i.d. } i=1,2,\ldots,n$, and let $X_{(i)}$ denote the $i$-th order statistic of $(X_i)$. In other words, $(X_{(i)} : i\text{-th smallest one among } X_1, \ldots, X_n)$
Then how can I find the distribution of $Y = X_1-X_{(1)}$?
I know that if $X_1$ is the minimum (which happens with probability $1/n$), $Y$ is $0$, but I don't know how to deal with the other cases.
$\newcommand{\e}{\operatorname{E}}$ Suppose $x>0.$ Then \begin{align} \Pr( X_1 - X_{(1)} > x) & = \Pr(X_1 > X_{(1)}) \Pr(X_1 -X_{(1)} >x \mid X_1 > X_{(1)}) \\[10pt] & = \frac{n-1} n \Pr(X_1 - X_{(1)} > x \mid X_1 > X_{(1)}). \tag 0 \end{align} Let $J \in\{1,\ldots,n\}$ be the index $j$ for which $X_j = X_{(1)}.$ Then $J$ is uniformly distributed in $\{1,\ldots,n\}.$ So \begin{align} \Pr(X_1 - X_{(1)} > x\mid X_1 \ne X_{(1)}) & = \Pr(X_1-X_J> x\mid J\ne 1) \\[10pt] & = \e( \Pr( X_1 - X_J > x \mid J ) \mid J\ne 1 ). \tag 1 \end{align} But $\Pr(X_1-X_J>x\mid J=j)$ is the same for all $j\in\{2,\ldots,n\};$ thus as a function of $J$ it is constant on the set $J\ne 1.$ Thus the event $X_1-X_J>x$ is conditionally independent of $J$ given the event $J\ne1.$ Therefore the expected value in $(1)$ is the expected value of a constant random variable, and so the expected value is equal to that constant. And the constant is $\Pr(X_1-X_j>x\mid J=j),$ for any $j\in\{2,\ldots,n\}.$ So it is the same as $\Pr(X_1-X_2 > x\mid X_1>X_2).$ Now the memorylessness of the exponential distribution tells us that that is $\Pr(X_1> X_2+x\mid X_1>X_2) = e^{-x}.$ So line $(0)$ above becomes $\dfrac{n-1} n \cdot e^{-x}.$
The bottom line is that for $x\ge0$ we have $$ \Pr(X_1-X_{(1)} \le x) = \frac 1 n + \frac{n-1} n ( 1 - e^{-x}) = 1 - \frac{n-1} n e^{-x}. $$