Example 5 In the expansion of $(a+b)^{n}$, how many coefficients are odd?
Proof Let $n=\left(a_{t} a_{t-1} \cdots a_{0}\right)_{2}$,
$$
m=\left(b_{t} b_{t-1} \cdots b_{0}\right)_{2} \text {, }
$$

where, $a_{i} 、 b_{i} \in\{0,1\}, i=0,1, \cdots, t, a_{t} \neq 0$.
By Theorem 3, we know
$\mathrm{C}_{n}^{m}$ is odd
$$
\begin{aligned}
\Leftrightarrow & \left(a_{i}, b_{i}\right)=(0,0),(1,0),(1,1), i=0, \\
& 1, \cdots, t .
\end{aligned}
$$

Therefore, when $\mathrm{C}_{n}^{m}$ is odd, the binary digit $b_{i}$ of $m$ has exactly $2^{a_{i}} \in\{1,2\}$ choices.

By the principle of multiplication, the number of odd numbers among $\mathrm{C}_{n}^{0}, \mathrm{C}_{n}^{1}, \cdots, \mathrm{C}_{n}^{n}$ is
$$
2^{a_{0}} 2^{a_{1}} \cdots 2^{a_{t}}=2^{S(n)},
$$

where, $S(n)=a_{t}+a_{t-1}+\cdots+a_{0}$.