Solution (source code)

= Solution

The <cardinal sum> is the <cardinality> of a disjoint <union>, and the <cardinal product> is the <cardinality> of the set of choice functions:
$$
\boxed{\sum_{\alpha<\beta}\kappa_\alpha=
\left|\{(\alpha,\xi):\alpha<\beta,\ \xi<\kappa_\alpha\}\right|,\qquad
\prod_{\alpha<\beta}\kappa_\alpha=
\left|\{f:\operatorname{dom}f=\beta,\ f(\alpha)<\kappa_\alpha\}\right|.}
$$
Here the cardinals are represented by <initial ordinals>. Tagging by $\alpha$ makes the summands disjoint even when their underlying sets overlap. For an empty index set the sum is zero and the product is one, because there is exactly one <empty function>. If any factor in a nonempty product is zero, that product is empty.