Evaluation of the double integral $\int_{[0,1]×[0,1]} \max\{x, y\} dxdy$ Evaluate:  $$\int_{[0,1]×[0,1]} \max\{x, y\} dxdy$$




I am totally stuck on it. How can I solve this?
$$
\begin{align*}
\int_0^1 \int_0^1 \max(x, y) dx dy &amp;= \int_0^1 \int_0^y y dx dy + \int_0^1 \int_y^1 x dx dy \\
&amp;= \int_0^1 y^2 dy + \int_0^1\frac{1 - y^2}{2} dy \\
&amp;= \frac{1}{2}\int_0^1 (y^2 + 1) dy \\
&amp;= \frac{1}{2}\left( \frac{1}{3} + 1\right) = \frac{2}{3}
\end{align*}$$
In general, the integral
$$I_n=\int_{[0,1]^n}\max\{x_1,\cdots,x_n\}\,\mathrm{d} x_1\cdots\mathrm{d}x_n$$
can be viewed as an integral of the largest order statistic, say $X^{(1)}$.

Let $x^{(1)}=\max \{x_1,\cdots,x_n\}$, the distribution of $X^{(1)}$ will be $$F_{X^{(1)}}(x)=F_{X_1}(x)\times\cdots\times  F_{X_n}(x)=x^n.$$
Hence
$$I_n=\int_{[0,1]^n}\max\{x_1,\cdots,x_n\}\,\mathrm{d} x_1\cdots\mathrm{d}x_n=\int_{[0,1]}x\,\mathrm{d}F_{X^{(1)}}(x)=\int_0^1 nx^n\,\mathrm{d}x=\frac{n}{n+1}.$$