Handbook
Glossary
safe? ( board q -- ? )
Vocabulary
rosetta-code.n-queens
Inputs
board
an
object
q
an
object
Outputs
?
an
object
Definition
USING:
kernel
math
sequences
;
IN:
rosetta-code.n-queens
::
safe?
( board q -- ? )
[let
q board
nth
:>
x q
<iota>
[
x
swap
[
board
nth
]
keep
q
swap
-
[
+
=
not
]
[
-
=
not
]
3bi
and
]
all?
]
;