This is a classic Minesweeper game.
This tutorial is for the C language version: Large maps with a scrolling viewport Easy: 20×40 grid, 80 mines Medium: 30×60 grid, 250 mines Hard: 40×80 grid, 500 mines A 20×40 viewport scrolls smoothly as you move
Gameplay improvements
First-click safety — mines never spawn near your first reveal
Chord reveal: on an already-revealed number, press Space to auto-reveal all neighbors if you've flagged the right count Win detection and game-over mine reveal
Controls
| Key | Action |
|---|---|
| Arrow keys / WASD | Move cursor |
| Space / Enter | Reveal cell |
| F | Flag/unflag |
| H/J/K/L | Jump 10 cells |
| 1 / 2 / 3 | Switch difficulty |
| R | Restart |
| Q | Quit |