# Understanding the solution to a problem about a homogeneous Poisson process

This is probably easy, but right now I can't figure it out, so bear with me. The question is:

Let $$\{N(t),t\ge 0\}$$ be a homogeneous Poisson process on $$(0,\infty)$$ with rate $$\lambda$$. Let $$\{S_i, i=1,2,...\}$$ be the points of the Poisson process, such that $$S_1 . Define $$S_0=0$$. The distribution of $$S_1$$ is Exp($$\lambda$$). For $$x\in[0,T]$$ compute $$P[T-S_n>x|N(T)=n]$$, $$E[T-S_n|N(t)=n]$$ and $$E[T-S_{N(T)}]$$.

There is a solution-manual for this, and I've tried to read it, but I don't understand everything in it. And that is why I need some help.

For $$P[T-S_n>x|N(T)=n]$$ it says that "by using the order statistic-property the answer is $$(\frac{T-x}{T})^n$$. I understand that we want to compute the probability that all the $$n$$ points falls into the interval $$(0,T-x)$$, but from there to how we get $$(\frac{T-x}{T})^n$$ I don't understand.

Also, the solution-manual says that when you compute $$E[T-S_n|N(t)=n]$$, you should use the "standard identity" of $$E(X)=\int_{0}^{\infty} P(X>x) dx$$. What do they mean? I thought that the standard identity was $$E(X)=\int_{0}^{\infty} x f(x) dx$$?

(If you want to vote down my question, fine, but if the reason is that the question is easy for you, please answer it before you do that)