Question 106
Let $m, n \ge 2$ be integers, $X = \{1, 2, \dots, n\}$, and let $X_1, X_2, \dots, X_m$ be $m$ distinct non-empty subsets of $X$ (not necessarily disjoint). A function $f : X \to \{1, 2, \dots, n+1\}$ is called *nice* if and only if there exists an index $k$ such that
$$
\sum_{x \in X_k} f(x) \gt \sum_{x \in X_i} f(x) \text{ for all } i \neq k.
$$
Prove that the number of nice functions is at least $n^n$.
$$
\sum_{x \in X_k} f(x) \gt \sum_{x \in X_i} f(x) \text{ for all } i \neq k.
$$
Prove that the number of nice functions is at least $n^n$.