$6 \cdot 30$ For a given positive integer $n$, let $p(n)$ denote the product of the non-zero digits of $n$ (if $n$ is a single digit, then $p(n)$ is equal to that digit). If
$$
S=p(1)+p(2)+p(3)+\cdots+p(999),
$$

what is the largest prime factor of $S$?
［Solution］Since
$$
\begin{aligned}
(a+1+2+\cdots+9)^{3}= & a \cdot a \cdot a+a \cdot a \cdot 1+a \cdot a \cdot 2+\cdots \\
& +9 \cdot 9 \cdot 8+9 \cdot 9 \cdot 9
\end{aligned}
$$

on the left side, when $a=1$, except for the first term, the rest is exactly equal to
$$
\begin{array}{l}
p(1)+p(2)+p(3)+\cdots+p(999) \text {, therefore } \\
S=(1+1+2+\cdots+9)^{3}-1 \\
=46^{3}-1 \\
=3^{3} \cdot 5 \cdot 7 \cdot 103 \text {, } \\
\end{array}
$$
the largest prime factor of $S$ is 103.