Draw two squares to isolate each person.
You need to add two squares in the picture below such that each dog is in isolation?
Connect all 9 dots, without lifting your pen, draw upto 4 lines.
Move 6 matches to create 2 squares.