Let $X_1, X_2$, ⋯ ∼ Unif(0,1) IID and $N_1$ = min{ n : $X_1 + ⋯ + X_n$ > 1}. Let $S_n = X_1 + ⋯ + X_n$. Compute E[$S_{N_1}$].
My approach: $$ E[S_{N_1}] = E[E[S_{N_1}|N_1]] $$ $$ E[S_{N_1}|N_1] = \int_0^1\int_0^{1-x_1}...\int_0^{1-x_1-...-x_{n-2}}\int_{1-x_1-x_2-...-x_{n-1}}^1(x_1 + x_2 + ... +x_n)dx_n \cdot dx_{n-1} \cdot ... dx_1 $$ Now, I am unable to go further, also I wonder is there a better approach to this? (Probably something with less integration)
P.S.: PDF of $N_1$ is given by $P(N_1 = n) = \frac{n-1}{n!}$, if that helps
\begin{eqnarray*} S_{N_1} & = & X_1 + \sum_{j=2}^{\infty}X_j\mathbb{1}_{X_1+\cdots+X_{j-1}\leq 1}\end{eqnarray*} where $\mathbb{1}_{X_1+\cdots+X_{j-1}\leq 1}$ takes value $1$ if $X_1+\cdots+X_{j-1}\leq 1$, and $0$ otherwise. In other words, it takes value $1$ if $N_1\geq j$, and $0$ otherwise. Therefore, by independence of $X_i$s, \begin{eqnarray*} \mathbb{E}\left(S_{N_1}\right) & = & \mathbb{E}\left(X_1\right)+\sum_{j=2}^{\infty}\mathbb{E}\left(X_j\right)\mathbb{E}\left(\mathbb{1}_{X_1+\cdots+X_{j-1}\leq 1}\right) \\ & = & \frac{1}{2}+\sum_{j=2}^{\infty}\mathbb{E}\left(X_j\right)\Pr\left(X_1+\cdots+X_{j-1}\leq 1\right) \\ & = & \frac{1}{2}+\sum_{j=2}^{\infty}\mathbb{E}\left(X_j\right)\Pr\left(N_1\geq j\right) \\ & = & \frac{1}{2}+\sum_{j=2}^{\infty}\left[\frac{1}{2}\left(\sum_{n=j}^{\infty}\left(\dfrac{n-1}{n!}\right)\right)\right] \\ & = & \frac{1}{2}+\sum_{j=2}^{\infty}\left[\frac{1}{2}\left(\sum_{n=j}^{\infty}\left(\dfrac{1}{(n-1)!} - \dfrac{1}{n!}\right)\right)\right] \\ & = & \sum_{j=1}^{\infty}\frac{1}{2(j-1)!} \\ & = & \frac{e}{2}\end{eqnarray*}