Sweeper's Dillemma

Limits: 15s, 512 MB

Minesweeper is a popular single-player puzzle video game from the 60’s. It still enjoys the privilege to get shipped with popular operating systems. Many people, unaware of the rules of this game, makes random clicks and end up losing the game. It is true that in some cases, this game requires a bit of luck. But mostly, this is a puzzle. The implementation of this game requires Depth-First Search and lets you brag about your algorithmic skills to your C instructor.

This is a companion discussion topic for the original entry at https://toph.co/p/sweeper-s-dillemma