{Maximum of independent exponential R.V} need help to understand I have question about this question



*

*What I don't understand
I do understand that P(2nd_max of {X1, X2....Xn}< t) = P(X1< t) P(X2< t).... P( Xn-1 < t). This will become the (1-e^(-lamda*t))^(n-1)), which is the second term above. 
However, I don't understand why we have the term "nexp(-lamda*t)" there. Can you guys please explain?
 A: It looks slightly strange to me too, especially since the given answer is not strictly increasing.
The probability that $X_1\gt t$ and all the other $X_i \le t$ is $e^{-\lambda t} (1-e^{-\lambda t})^{n-1}$.  Hence the $e^{-\lambda t}$ term. 
The probability that $X_2\gt t$ and all the other $X_i \le t$ is the same, and so on.  So the probability that exactly one is greater than $t$ and all the others less than or equal to $t$ is  $ne^{-\lambda t} (1-e^{-\lambda t})^{n-1}$ as stated in the given answer. Hence the $n$ term.
But you also have to add the probability that all $n$ of the  $X_i \le t$, which is  $(1-e^{-\lambda t})^{n}$.  And so $P(Y \le k) = ne^{-\lambda t} (1-e^{-\lambda t})^{n-1} +(1-e^{-\lambda t})^{n}=$ $$(1+(n-1)e^{-\lambda t} )(1-e^{-\lambda t})^{n-1}.$$
A: I don't know where the solution is from, but I think it's wrong. 
Actually, for $t \geq 0$, $Y \leq t$ iff 
(i) $\exists j \in \{1,...,n\}$ such that $X_i \leq t \quad \forall i \neq j$ and $X_j > t$; $\quad$OR
(ii) $X_j \leq t \quad \forall j \in \{1,...,n\}.$
The solution misses out the second possibility. We can then calculate as follows:
$$ P(Y \leq t) = P(X_1 \leq t ,..., X_n \leq t) + \sum_{j=1}^n P(X_i \leq t \quad \forall i \neq j \quad \textrm{and} \quad  X_j > t).$$
Because the random variables in the sum are identically distributed, and there are $n$ terms in the sum, the sum term becomes $$ e^{-\lambda t} (1- e^{-\lambda t})^{n-1} $$ and the first term euqals $$n(1- e^{-\lambda t})^n$$.
Factorising, this gives $$ P(Y \leq t) = [(n-1) e^{-\lambda t} +1](1- e^{-\lambda t})^{n-1}.$$
