On this blueprint every square denotes a room. Some doors between rooms have to be closed. Open doors allow to look into other rooms. If a square contains a number, this number indicates how many rooms can be seen from that position, the room itself excluded.

To solve this example, we will start in the upper right corner where there are a 2 and a 5 next to eachother. The 5 needs to see five rooms, but horizontally it can see at most two: after all, otherwise the 2 would see more than two rooms. Vertically the 5 can see at most three rooms. Conclusion: the three doors below the 5 are all open, and the door two rooms to the left of the 5 is closed. The 2 now already sees two rooms, so the door below the 2 is closed.

The 2 in the top left can not look to the right, and therefore has to see two rooms downwards. The door below that has to be closed. In the same way the 1 in the lower left sees the room to the right. The 4 in the lower right sees exactly three rooms upwards, so the door to the left of it must remain open as well.

All remaining numbers have the number of rooms they see either horizontally or vertically already fixed, which makes it very easy in this case to finish the puzzle.

.