Hello,
We are currently doing a minesweeper in the course TDA452 and we have a question, since we ran into trouble.
The question is can you generate a field which you then play on during the game? We can generate a field, but we dont know how to use it after the generation.
This is how we generate the field.
instance Arbitrary Minefield where
arbitrary =
do rows <- sequence [ sequence [ cell | j <- [1..10] ] | i <- [1..10] ]
return (initField (Minefield rows))
Thanks in advance