summaryrefslogtreecommitdiff
path: root/.stack-work/intero/intero18425meY-STAGING.hs
diff options
context:
space:
mode:
Diffstat (limited to '.stack-work/intero/intero18425meY-STAGING.hs')
-rw-r--r--.stack-work/intero/intero18425meY-STAGING.hs46
1 files changed, 0 insertions, 46 deletions
diff --git a/.stack-work/intero/intero18425meY-STAGING.hs b/.stack-work/intero/intero18425meY-STAGING.hs
deleted file mode 100644
index 820de4e..0000000
--- a/.stack-work/intero/intero18425meY-STAGING.hs
+++ /dev/null
@@ -1,46 +0,0 @@
1module Main where
2
3import Control.Lens
4import Linear.V2
5import Linear.V3
6import Data.Matrix
7import System.Random
8
9data Square = X | Q deriving (Show)
10--board = V3 <$> [0..8] <*> [0..8] <*> [0]
11--board = [(r,c,X) | r <- [0..8], c <- [0..8] ]
12
13lo8 = [0..8] -- list of 8
14initBoard = matrix 8 8 $ \_ -> X
15--avail r c b =
16
17--rowOccupied r b = any (== Q) $ getRow r b
18placeQueen r c b = setElem Q (r,c) b
19
20--placeAll = repeat 8 placeQueen
21
22winnable = undefined
23
24-- placeQueen r c =
25
26--b = getE
27
28--placeQueen r c b = b ^.
29
30-- rand = do
31-- g <- newStdGen
32-- print $ take 8 $ (randomRs (0, 8) g)
33
34
35-- try r c = let next b = placeQueen r c b
36-- in next initBoard
37
38-- try' p = let next b = p b
39-- in next initBoard
40
41
42--res = [ try x y | x <- lo8, y <- lo8 ]
43
44main :: IO ()
45main = do
46 putStrLn "Hi"