There was a similar thread awhile back where I posted Visual C++ source code in [post=536867]this post[/post] for a program that did something similar to what is being discussed in this thread. I note I only considered 13! letter orderings rather than full 21! orderings. But I posted source code so you can try to adapt it as you please.