shenzhen
Solves games of Shenzhen Solitaire, a minigame available standalone or as part of Shenzhen I/O from Zachtronics.
Written for practice with Haskell and HaskellStack.
TODO
- create Stack project
- types for cards
- create standard deck
- Layout type
- custom Show instances for Card, Layout
- enter game Layout
- shuffle deck to create Layout
- Game type
- Use standard terms https://en.wikipedia.org/wiki/Glossary_of_patience_terms
- Move type for card moves, collecting dragons
- move :: Game -> Move -> Game
- Automatic moves of available cards
- Detect game win
- Detect game loss
- Generate list of possible Moves for a position
- Filter possible Moves against Game history to avoid loops
- Take moves until game win/loss
Cleanups:
- Encode that
Gamehas exactly oneFoundationperSuit - Look at
BoundorEnumforRank
