Skip to content

rshest/gchq-christmas-puzzle

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MiniZinc solution to the first step of the "Christmas GCHQ Puzzle":

The constraints:

It is similar to the Sudoku puzzle, with a little bit more complex vertical/horizontal constraints.

  • The first constraint is for the "fixed" cells to be in place
  • The other two (almost identical) groups of horizontal/vertical constraints ensure that:
  • The provided intervals have 1's all along
  • Every interval (except of the first one) has a preceding 0 AND the intervals do not overlap
  • The total amount in 1's in every row/column is the same as the sum of the provided intervals' lengths
The puzzle itself:

In this type of grid-shading puzzle, each square is either black or white. Some of the black squares have already been filled in for you. Each row or column is labelled with a string of numbers. The numbers indicate the length of all consecutive runs of black squares, and are displayed in the order that the runs appear in that line. For example, a label "2 1 6" indicates sets of two, one and six black squares, each of which will have at least one white square separating them.”

About

MiniZinc solution to the first step of the "GCHQ" Christmas puzzle

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published