dsimcha, I think the struct to generate permutations is out of place there, and more fit in a module like the comb (combinatorics) of mine. Beside that detail, I like the idea of having a standard module with basic statistics, so I am interested :-) Bye, bearophile