I think this problem is a huge can of worms smile

I found this site

http://home.halden.net/vkp/vkp/layouts.html

It seems you can either go the random route(often unwinnable)or set up many predefined patterns with no algorithm(always winnable).

This though may help

http://www.formauri.es/personal/pgimeno/mj/mjsol.html

Hope this clears up the nature of your problem.

Last edited by TigerTao; 06/22/08 23:07.