brainwagon "There is much pleasure in useless knowledge." — Bertrand Russell


92 ways to place 8 queens on a chessboard…

such that no queen attacks any other queen. It's a simple (really simple) program to write, but I can't remember having done it. So I did it. And then I had to make a picture of one of the solutions.

8 queens on the chessboard

Technorati Tags: , , ,

Addendum: Wikipedia has a page on the puzzle, naturally. This kind of program would be a good one to test out Knuth's "Dancing Links" idea. I might have to do that.

Addendum2: I swiped the chess font and methodology from this website, keeping with my long tradition of drawing stuff on my website using PostScript.

Addendum3: I made a different picture using the Adobe Cheq font:

8 Queens using Adobe Cheq font

Filed under: General Leave a comment
Comments (0) Trackbacks (1)

Leave a comment