Let (a1, a2, …, am), a i ∊ {l, 2, …, n}, be an m-permutation of n (repetitions allowed) with exactly kj of the a's equal to j, j = 1, 2, …, n, m = k 1+ …+kn , fixed nonnegative integers. An inversion is a pair i, j such that i < j, ai > aj . Denote by N(r; k, …, kn) the number of such permutations with exactly r inversions.