= Solution
Enumerate $A$ as $a_1,\ldots,a_a$. A <function> is specified by choosing the image of each of these elements independently, with $b$ possibilities each. The <multiplication principle> gives $\boxed{b^a\text{ functions}}$.
For an <injective function>, successive images must be distinct. If $a\le b$, there are $b$ choices for the first, $b-1$ for the second, and so on. If $a>b$, the <pigeonhole principle> makes injectivity impossible. Thus the number of <injective functions> is
$$
\boxed{\begin{cases}
\displaystyle b(b-1)\cdots(b-a+1)=\frac{b!}{(b-a)!},&a\le b,\\
0,&a>b.
\end{cases}}
$$
The product in the first case is a <falling factorial>.
Back to article page