156. In how many ways can $2^{n}$ be expressed as the sum of four squares of positive integers?
156. Let

$$
a^{2}+b^{2}+c^{2}+d^{2}=2^{n}
$$

Denote the highest power of two by which all four numbers $a, b, c$ and $d$ are divisible as $p$. By dividing both sides of our equation by $2^{2 p}$, we get:

$$
a_{1}^{2}+b_{1}^{2}+c_{1}^{2}+d_{1}^{2}=2^{n-2 p}
$$

where at least one of the four numbers $a_{1}, b_{1}, c_{1}, d_{1}$ is odd.

If out of the four numbers $a_{1}, b_{1}, c_{1}, d_{1}$ only one or three are odd, then $a_{1}^{2}+b_{1}^{2}+c_{1}^{2}+d_{1}^{2}$ is odd, and our equation is impossible. If out of the numbers $a_{1}, b_{1}, c_{1}, d_{1}$ two, for example $a_{1}=2 k+1$ and $b_{1}=2 l+1$, are odd, and the other two, $c_{1}=2 m$ and $d_{1}=$ $=2 n$, are even, then we have:

$$
\begin{aligned}
& a_{1}^{2}+b_{1}^{2}+c_{1}^{2}+d_{1}^{2}=4 k^{2}+4 k+1+4 l^{2}+4 l+1+4 m^{2}+4 n^{2}= \\
&=2\left[2\left(k^{2}+k+l^{2}+l+m^{2}+n^{2}\right)+1\right]
\end{aligned}
$$

which contradicts the fact that $a_{1}^{2}+b_{1}^{2}+c_{1}^{2}+d_{1}^{2}=2^{n-2 p}$ has no odd divisors (the expression in square brackets cannot equal one, as in that case we would have $k=l=$ $=m=n=0, c_{1}=d_{1}=0$ and $c=d=0$). If all four numbers $a_{1}=2 k+1, b_{1}=2 l+1, c_{1}=2 m+1, d_{1}=2 n+1$ are odd, then we have:

$$
\begin{aligned}
a_{1}^{2}+b_{1}^{2}+c_{1}^{2}+d_{1}^{2}= & 4 k^{2}+4 k+1+4 l^{2}+4 l+1+4 m^{2}+4 n_{2}= \\
& +4 m+1+4 n^{2}+4 n+1= \\
= & 4[k(k+1)+l(l+1)+m(m+1)+n(n+1)+1]
\end{aligned}
$$

But the product of two consecutive integers is always even (one of the factors is necessarily even). Therefore, the expression in square brackets is odd, and thus it equals 1. Thus, $n-2 p=2, n=2 p+2$ and $k=l=m=n=0$, $a_{1}=b_{1}=c_{1}=d_{1}=1, a=b=c=d=2^{p}$.

Therefore, if $n$ is an odd number, then $2^{n}$ cannot be expressed as the sum of four squares; if $n=2 p$ is even, then $2^{n}$ admits a unique decomposition

$$
2^{2 p}=\left(2^{p-1}\right)^{2}+\left(2^{p-1}\right)^{2}+\left(2^{p-1}\right)^{2}+\left(2^{p-1}\right)^{2}
$$