Draw a closed loop through the diagram by connecting some of the dots horizontally or vertically. The loop is not allowed to touch or cross itself. The digits give the number of loop segments directly above, under, or next to the digit. In these puzzles all sheep are supposed to be contained within the loop (the fence), while all the wolves should be kept outside.
The 1 in the lower left corner can only have a fence at the top (all others would need to be connected with yet another fence bordering one of the two 1's there, violating a constraint), and has to proceed to the left of the 2. Since the 2 cannot have any more fences, there is a fence part between the 2 and the 3, and similarly between the other 2 and the 3. The other side of the fence must go to the right, so the remaining 2 must have a fence at the top and one at the bottom. Since everything must be connected, the upper part of the fence has to return and the lower part goes on to the right edge of the field.
This genre was invented by Nikoli. Sheep and wolves were first added by Dave Tuller.
Puzzles in this genre