English

Solving Mahjong Solitaire boards with peeking

Computational Complexity 2012-04-04 v1 Discrete Mathematics Data Structures and Algorithms

Abstract

We first prove that solving Mahjong Solitaire boards with peeking is NP-complete, even if one only allows isolated stacks of the forms /aab/ and /abb/. We subsequently show that layouts of isolated stacks of heights one and two can always be solved with peeking, and that doing so is in P, as well as finding an optimal algorithm for such layouts without peeking. Next, we describe a practical algorithm for solving Mahjong Solitaire boards with peeking, which is simple and fast. The algorithm uses an effective pruning criterion and a heuristic to find and prioritize critical groups. The ideas of the algorithm can also be applied to solving Shisen-Sho with peeking.

Cite

@article{arxiv.1203.6559,
  title  = {Solving Mahjong Solitaire boards with peeking},
  author = {Michiel de Bondt},
  journal= {arXiv preprint arXiv:1203.6559},
  year   = {2012}
}

Comments

10 pages

R2 v1 2026-06-21T20:41:55.077Z