  We use the generating function approach to derive simple expressions for the
factorial moments of the distance distribution over Reed-Solomon codes. We
obtain better upper bounds for the error term of a counting formula given by Li
and Wan, which gives nontrivial estimates on the number of polynomials over
finite fields with prescribed leading coefficients and a given number of linear
factors. This improvement leads to new results on the classification of deep
holes of Reed Solomon codes.
