5 queens

cf29 fcharlypillai at gmail.com
Sat Dec 22 17:31:46 EST 2007


On Dec 22, 11:05 pm, Dennis Lee Bieber <wlfr... at ix.netcom.com> wrote:
>         Only 5? The classic algorithm is 8-queens on a standard 8x8 board,
> as I recall...

This is a different problem. You have to control all the squares with
only 5 queens.
In the 8 queens problem you have to put 8 "safe queens".
I also have it on my website at http://www.cf29.com/design/dame_eng.php

I know about the Wikipedia 8 queens solution and it is how I
discovered Python. I wanted to learn more about it to try to modify
this script for the 5 queens problem. It helped me to go as far as I
did with my 5 queens script but the 8 queens script only considers a
number of queens equal to the number of rows. In the 5 queens problem,
there are 8 rows and 3 of them are empty.

It may be not particularly related to Python so may be my message is
misplaced. Thanks for the help anyway.



More information about the Python-list mailing list