Cave (also called Bag or Corral) is a Nikoli logic puzzle genre.

  • Shade some cells in the grid.
  • All shaded cells must be connected to the outside of the grid.
  • All unshaded cells must be connected.
  • Clue cells must not be shaded, and represent the total number of cells in the union of orthogonal lines of unshaded cells from the clue cell (including the clue cell itself).

Note that there is an equivalent ruleset involving a loop enclosing all clue cells.