Shlomi Fish avatar Shlomi Fish committed 31629f7

Start writing a document with Nurikabe strategies.

These are strategies that help me as a human solver of Nurikabe, and may
help in writing solvers.

Comments (0)

Files changed (1)

docs/Nurikabe_Strategies.txt

+# vim:ft=txt
+
+#. Proximity analysis - some cells can be eliminated because they are not
+reachable (also consider that white cells of certain islands interfere
+with the extent of different islands).
+
+#. A straight row or column of black cells can be tested for black cells in
+its middle which will place two white cells and so one can conclude that
+they are white.
+
+#. If you have something like:
+
+   |[B][G][B]
+   |[G][G][B]
+   -----------------
+
+Then it is evident that the upper [G] (Gray/Unknown) has to be white, or else
+the lower [G]s will also all be black.
+
+#. Cells between two islands (either diagonally or in a one-cell spacing) must
+be black, or else the two islands will be joined.
+
+#. Filling-style strategy: if past a certain geometery (that is within the
+limits of its number), an island can only expand into one cell, then that
+cell will be white.
+
+#. If an Island reaches certain points that reaching them consumes all of its
+number, then its white edge points can be marked with black in the opposite
+direction to its extent.
+
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.