sbv-1.3: Symbolic bit vectors: Bit-precise verification and automatic C-code generation.

Portabilityportable
Stabilityexperimental
Maintainererkokl@gmail.com
Safe HaskellSafe-Infered

Data.SBV.Examples.Puzzles.NQueens

Description

Synopsis

Documentation

type Solution = [SWord8]Source

A solution is a sequence of row-numbers where queens should be placed

isValid :: Int -> Solution -> SBoolSource

Checks that a given solution of n-queens is valid, i.e., no queen captures any other.

nQueens :: Int -> IO ()Source

Given n, it solves the n-queens puzzle, printing all possible solutions.