Programmer's Minesweeper

Programmer's Minesweeper (PGMS) is a game based on the Minesweeper game delivered with most Microsoft Windows operating systems. In that game, a grid of cells is presented to the player. If the player probes a cell with a mine, the game is lost. If the player probes a cell without a mine, the player learns the number of mines that are adjecent to the probed cell. This information can often be used to choose another cell for probing without fear it has a mine. The game is won when every cell without a mine has been probed.

In this version of Minesweeper, a Java program plays the game. Minesweeper players sometimes enjoy watching the computer play an expert game, and learn to use some of its tricks.

Programmer's Minesweeper has been designed so that Java programmers can easily implement their own strategy for winning a Minesweeper game. A very simple strategy has been implemented called the Single Point Strategy. Click on the start button in the mine map below to see it play a beginner game. A yellow cell indicates a mine with a location unknown to the strategy, a blue cell indicates a mine correctly marked by the strategy, a red cell indicates an exploded mine, and a black cell indicates an incorrectly marked cell.

The dynamic behavior of this applet is only available to users of Java aware browsers.
Key: yellow: hidden mine, blue: marked mine, red: probed mine, black: marked emply cell.

A Zip archive of the complete sources
John D. Ramsdell