Index of /anton/lvas/stack-abgaben/09w/8queens

[ICO]NameLast modifiedSizeDescription

[PARENTDIR]Parent Directory  -  
[   ]8queens.fs2010-01-29 14:30 959  

README - 8 Queens Problem
=========================

# Authors
Josef Pfleger, Gottfried Poell

The eight queens puzzle is the problem of placing eight chess queens on an 8×8 chessboard such that none of them are able to capture any other using the standard chess queen's moves. The queens must be placed in such a way that no two queens would be able to attack each other. Thus, a solution requires that no two queens share the same row, column, or diagonal.

# Usage
gforth 8queens.fs
n solve

[n] number of printed solutions

# Example

[ss9373828:~:4] gforth 8queens.fs 
Gforth 0.6.2, Copyright (C) 1995-2003 Free Software Foundation, Inc.
Gforth comes with ABSOLUTELY NO WARRANTY; for details type `license'
Type `bye' to exit
1 solve 
0|*| | | | | | | |
1| | | | | | |*| |
2| | | | |*| | | |
3| | | | | | | |*|
4| |*| | | | | | |
5| | | |*| | | | |
6| | | | | |*| | |
7| | |*| | | | | |
 ok