= Solution
Let $x_i$ be the number in box $i$ and put $y_i=x_i-1$. We count <integer compositions> satisfying $y_1+\cdots+y_4=6$ and $0\leq y_i\leq4$. Without the upper bounds, <stars and bars> gives $\binom93=84$. If a specified $y_i\geq5$, subtract five from it; the remaining <nonnegative integer> variables sum to one, giving $\binom43=4$ possibilities. Two violations cannot occur because they would require a sum at least ten. The <inclusion-exclusion principle> therefore gives
$$
\boxed{\binom93-4\binom43=84-16=68.}
$$
The boxes are distinguished by their positions in the composition; individual objects are not distinguished.
Back to article page