Solution
= Solution
Split the unit square into $v\le u$ and $v>u$. The maximum is $u$ on the first triangle and $v$ on the second, so
$$
\begin{aligned}
\mathbb E[U\max\{U,V\}]
&=\int_0^1\left[\int_0^u u^2\,dv+\int_u^1 uv\,dv\right]du\\
&=\int_0^1\left[u^3+\frac u2(1-u^2)\right]du\\
&=\frac18+\frac14=\boxed{\frac38}.
\end{aligned}
$$
The shared boundary has zero <probability>, so it is not counted twice in this <joint density> calculation.