Skip to content

rkat0/Godomachi

Repository files navigation

About Godomachi

Explanation of this game by inventor : https://j344.exblog.jp/238344979/

Requirements

  • GHC

Compile ghc godomachi.hs.

How to use

All combination

$ ./godomachi <n>

Analyze all combination of n-omino except same ones. ( n > 8 : not tested )

Example:

$ ./godomachi 4
4-ominoes : 5
total patterns : 10 (= 5 * 4 / 2)
        first  : 10
                 [(1,10)]
        second : 0
                 []

When n = 4, first player wins in all patterns with 1 step.


Single board

$ ./godomachi

Then input two polyominoes separated by a blank line.

  • block : #
  • blank : other character

Example:

$ ./godomachi
##
###

 #
###
#
----------


##.
###

.#.
###
#..

----------

#
#

.#.
.##

.#.
.##

----------

First player wins in 1 step(s)!

Single board (all first moves)

$ ./godomachi --first

Same as above, but check all first move patterns and list patterns by which first player wins.

Example:

$ ./godomachi --first
###
 #
 #

####
#
----------

Initial board

###
.#.
.#.

####
#...

----------

1 step(s)

#
#

###

.###

----------

1 step(s)

#

.##
.#.
.#.

###
#..

first wins by 2/6 pattern(s)


List polyominoes

$ ./godomachi --rank <n>

Print all n-ominoes.

Example:

$ ./godomachi --rank 4
All free 4-ominoes : 5
0
#
#
#
#

1
##
#.
#.

2
#.
##
#.

3
##
##

4
#.
##
.#

About

A checkmate search program of Godomachi.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published