Cops And thief devu

can anyone help me in this problem?would i require any other algo to do this?please help m just a beginner

2 Likes