by aardvark179 · 8y ago · 0 comments
Also, you probably want to stop clicks on marked squares from exploding the mine.
edit: [Shift] + Click to flag.
https://www.chiark.greenend.org.uk/~sgtatham/puzzles/doc/min...
https://www.chiark.greenend.org.uk/~sgtatham/puzzles/
They're all open source and I believe available on iOS as well as android for free for mobile users too.
The easiest thing to do is to write a solver which will iteratively mark squares it knows to contain a mine, or knows don’t contain a mine. If the solver can find all the mines the board is solvable. Only present the user with boards that your solver can solve.