When I am changing the order of isPossible function then it\'s giving wrong answer otherwise present code gives correct answer. I wanted to know why this is happening. Here