Find the distribution of $W$ Let $X \sim N(0,1)$ and $Y \sim N(0,1)$, independent. $$W = Y \;\;\text{if } Y-X >0, \;\;\;\;\;\;\;\;\; W = -Y \;\;\;\; \text{if } Y-X <0 $$
Then, find the distribution of $W$

Here is a my work so far. 
$$P(W < w) = P(W < w, X-Y < 0) + P(W < w, X-Y > 0) \\
=  P(Y \leq w, Y-X > 0) + P(-Y \leq w, Y-X < 0)\\
= \int_{-\infty}^{w}P(Y = y, X < y)dy + \int_{-w}^{\infty}P(Y=y, X>y)dy  $$
And actually I really think the third line is sort of wrong. Is that right? How do I solve it? 
 A: Continuing from the first part of your argument, 
\begin{align}
   F_W(w)
&= P[Y \leq w, X<Y] + P[Y \geq -w, Y < X] \\
&= P[(X,Y) \in \{(x,y) \mid x<y\leq w \}] + P[(X,Y) \in \{(x,y) \mid -w \leq y < x \}] \\
&= \int_{-\infty}^w \int_{-\infty}^y f(x) f(y) dx dy + 
   \int_{-w}^\infty \int_y^\infty f(x) f(y) dx dy \\
&= \int_{-\infty}^w f(y) F(y) dy  + 
   \int_{-w}^\infty f(y) (1-F(y)) dy \\
&= \left. \frac{1}{2}F(y)^2 \right|^w_{-\infty} + (1-F(-w)) - 
   \left. \frac{1}{2}F(y)^2 \right|^\infty_{-w} \\
&= \frac{1}{2}(F(w)^2 - 1 +F(-w)^2) + F(w) \\
&= \frac{1}{2}(F(w)^2 - 1 +2F(w) +(1-F(w))^2) \\
&= F(w)^2
\end{align}
where $f$ and $F$ are the normal pdf and distribution respectively. So $W$ has density $f_W(w) = 2f(w)F(w)$ and is not normal $N(0,1)$.
The expected value of $W$ is then
\begin{align}
   {\bf E}[W]
&= 2\int_{-\infty}^0 x f(x)F(x) dx + 2\int_0^\infty x f(x)F(x) dx \\
&= 2\int_0^\infty (-x) f(-x)F(-x) dx + 2\int_0^\infty x f(x)F(x) dx \\
&= -2\int_0^\infty x f(x)(1-F(x)) dx + 2\int_0^\infty x f(x)F(x) dx \\
&= 2\int_0^\infty x f(x)(2F(x)-1) dx 
\end{align}
which is strictly greater than $0$. I'm not sure how to solve this explicitly, but making the substitution $u = 2F(x)-1$ gives
$$
  {\bf E}[W]
= \int_0^1 u F^{-1}\left(\frac{u+1}{2}\right) du
= \sqrt{2}\int_0^1 u \text{ erf}^{-1}(u)du
$$
where $\text{erf}^{-1}$ is the inverse error function.
It has been remarked in the comments that this should equal $1/2$. It may be easier to make this determination by going back to the definition of $W$ and using a conditioning argument.
A: We introduce each hypothesis separately when it is needed, to show its specific use in the proof of the main result, which is:

The density of $W$ is $2\varphi\Phi$, in particular, $W$ is not normal but $W$ is distributed like $W'=\max\{X,Y\}$, and $E(W)=1/\sqrt\pi$.

To show this, assume first only that $X$ and $Y$ are independent and consider $F_X$ the CDF of $X$, then
$$
P(Y-X\gt0\mid Y)=P(X\lt Y\mid Y)=F_X(Y),
$$
and
$$
P(Y-X\lt0\mid Y)=1-F_X(Y).
$$
Hence, for every bounded measurable function $u$,
$$
E(u(Y);Y-X\gt0)=E(u(Y)P(Y-X\gt0\mid Y))=E(u(Y)F_X(Y)),
$$
and
$$
E(u(-Y));Y-X\lt0)=E(u(-Y)P(Y-X\lt0\mid Y))=E(u(-Y)(1-F_X(Y))).
$$
Summing these yields the general formula
$$
E(u(W))=E(u(Y)F_X(Y)+u(-Y)(1-F_X(Y))).
$$
Assuming furthermore that $Y$ has a density $f_Y$, one sees that $W$ has a density $g$ given by
$$
g(w)=F_X(w)f_Y(w)+(1-F_X(-w))f_Y(-w).
$$
Assuming furthermore that $Y$ is symmetric, that is, that $Y$ and $-Y$ have the same distribution, one deduces that $f_Y(w)=f_Y(-w)$ for every $w$, hence
$$
g(w)=(F_X(w)+1-F_X(-w))f_Y(w).
$$
Assuming furthermore that $X$ is symmetric, that is, that $X$ and $-X$ have the same distribution, one deduces that $1-F_X(-w)=F_X(w)$ for almost every $w$, hence
$$
g=2F_Xf_Y.
$$
Assuming furthermore that $X$ and $Y$ are identically distributed with PDF $f$ and CDF $F$, one sees that $g=(F^2)'$ hence the CDF $G$ of $W$ is
$$
G=F^2,
$$
in particular, $W$ is distributed like 
$$
W'=\max\{X,Y\}.
$$
To compute $E(W)$ when $X$ and $Y$ are i.i.d. standard normal, note that the standard normal PDF $\varphi$ is such that $w\varphi(w)=-\varphi'(w)$ hence an integration by parts yields
$$
E(W)=2\int w\varphi(w)\Phi(w)\mathrm dw=2\int \varphi(w)^2\mathrm dw.
$$
Furthermore, $\varphi(w)^2=\varphi(\sqrt2w)/\sqrt{2\pi}$ hence
$$
E(W)=\sqrt2\int \varphi(\sqrt2w)\mathrm d(\sqrt2w)/\sqrt{2\pi}=1/\sqrt\pi.
$$
