Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- queens n = [x | x <- permutations [1..n], all (s . m x) [(+),(-)]]
- where m x f = zipWith f [0..] x; s = (==) =<< nub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement