Mahjong [solitaire] Rules


Mahjong is the name of two different tile-based games that share nothing but the tileset and the name with each other. One of the games is a two-to-four-player game, which according to one myth was developed by Confucius in 500 BC. The other, the subject of this paper, is a single-player game created by Brodie Lockard from 1981 onwards. In 1986, the game gained popularity when it was released by Activision under the trademarked name Shanghai, also programmed by Lockard. From then on, literally hundreds of versions of the game were written, under names such as Mahjong, Mahjong Solitaire, or “the Turtle Game”.

Game Rules

A Mahjong position initially consists of a pile of 144 stones. The goal of the game is to remove all stones. In the context of this paper, a solved position is one where all stones are removed.
Each of the 144 stones in the game has a face. There are 36 distinct faces. Per face, there are four stones with that face. Stones have to be removed in matching pairs.
Flower tiles and Season tiles are bonus. Flowers are plum, orchid, chrysanthemum and bamboo.

Winter, Summer, Autumn and Spring decorated with pictures that may bear resemblance to the season.

When matching pairs, Seasons and Flowers are the only suits you do not need to match. Any Season or Flower combination counts as a pair because there is only one of each tile.
A Mahjong position is a pile of stones, all face up. For some stones, the face is obscured by other stones above. A stone can be removed when it is possible to “slide it” to the left (west) or right (east), with no stone (partially) covering it. A stone can not be removed when it is touched by other stones on the left and on the right, even when it is not touched in the north or south. A stone can also not be removed when there is a stone exactly or partially on top of it.
A stone that can be removed is called a free stone.

mahjong rules
In the Picture above, stone 2 is blocked by stones 1 and 3 because it can not move to the left or right, and it is not allowed to lift the stone vertically or to slide the stone towards the north or south.

majhong rules
The stones 4, 5, 6, and 7 are blocked because stone 8 lies partially on top of them.

mahjong help
Stone 10 is blocked on the left by stone 11, but free nonetheless as it can move freely to the right.

There are many ways to create a positions of 144 stones. While this game can also be played with real Mahjong stones, the set-up process for a position reveals some of the stones that are later obscured, thereby giving the player information he should not have and spoiling some of the “fun”. In this game, the solving strategies have no information on the faces of stones fully covered by other stones above, but full information on stones that are not or only partially covered. Also, it is not possible to backtrack, as otherwise the strategy could “cheat” and gather information on invisible stones by taking almost all stones, then backtracking up to the original pile, then use a perfect-information solver.